Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 30308

Summary: [Decorators] Flashing viewer refresh
Product: [Eclipse Project] Platform Reporter: Knut Radloff <knut_radloff>
Component: UIAssignee: Tod Creasey <Tod_Creasey>
Status: CLOSED FIXED QA Contact:
Severity: major    
Priority: P2 CC: airvine, daniel_megert, n.a.edgar
Version: 2.0   
Target Milestone: ---   
Hardware: PC   
OS: Windows 2000   
Whiteboard:
Attachments:
Description Flags
Screen shot showing one flashing state
none
Screen shot showing another flashing state none

Description Knut Radloff CLA 2003-01-27 11:20:16 EST
build 20030121

-I have a workspace with the UI plugins and the 
org.eclipse.swt/org.eclipse.swt.win32 plugins (v2122c/v2122) loaded.
-Searched all .java files for "formatName"
-Got six results in org.eclipse.swt.dnd.Transfer.java (different files and 
versions for different platforms)
->Double clicking on a search result causes flashing refreshes in the search 
results view and in the outliner. It looks like the version number decoration 
gets added and removed in an infinite loop.

I have the default team label decorators enabled and all team icon decorators 
disabled.
Comment 1 Knut Radloff CLA 2003-01-27 11:25:28 EST
Created attachment 3160 [details]
Screen shot showing one flashing state

Outliner and search view are both flashing
Comment 2 Knut Radloff CLA 2003-01-27 11:26:16 EST
Created attachment 3161 [details]
Screen shot showing another flashing state

Outliner stops flashing, search view still flashes.
Comment 3 Knut Radloff CLA 2003-01-27 11:27:54 EST
The flashing stopped in both views when I closed the open Transfer.java editor.
Comment 4 Tod Creasey CLA 2003-01-27 11:29:15 EST
Do you have anything in your .log?
Comment 5 Knut Radloff CLA 2003-01-27 12:24:32 EST
Only jdi TimeOutExceptions.
Comment 6 Andrew Irvine CLA 2003-01-27 12:33:45 EST
I saw the same behaviour on the 200301151011 build.  I had also just finished a 
search.  In my case the flashing stopped when I openned an .html document 
within eclipse.  It then started again when I started cycling through the 
searched documents via the navigation buttons of the search view.

Nothing in the log. 
Comment 7 Tod Creasey CLA 2003-01-27 14:25:00 EST
Replicated in 20030127
Comment 8 Tod Creasey CLA 2003-01-27 14:45:49 EST
The problem appears to be related to how the Java Outline and the Problem 
Marker manager interact (I am having some trouble with out of memory errors so 
debugging has been a challenge). I am adding Dani to the cc list as he likely 
has some insight.

The problem seems to go this way:

1) Double click on an entry in the search view to open it
2) This causes the outline view to populate which then calls the decorator
3) Decorator will eventually send a labelProviderChanged
4) Problem marker picks this up and sends its own label provider changed
5) Decorator has already returned the answer from the first request so it 
fires off a second one
6) Cycle continues until the OutlineView gets a different input (switch 
editor).

I am not sure about the transition from 3 to 4 - perhaps Dani can shed some 
light.
Comment 9 Tod Creasey CLA 2003-01-28 09:55:47 EST
Turns out that the problem was with adaptability. I was storing the result in 
terms of the JavaElement and the SearchView was asking for it for the IFile. 
As a result I was queueing another decoration and around it went.

We now cache the adapted result and the adapted+original result and send 
updates for the original.

Well spotted Knut - this was a toughie.

Fixed in build >20030128.
Comment 10 Tod Creasey CLA 2003-02-04 12:10:18 EST
*** Bug 30882 has been marked as a duplicate of this bug. ***
Comment 11 Tod Creasey CLA 2005-05-10 14:56:09 EDT
Marking closed