Bug 1982 - [Viewers] StructuredViewer#setSelection(ISelection, boolean) (1GD2ACL)
Summary: [Viewers] StructuredViewer#setSelection(ISelection, boolean) (1GD2ACL)
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 2.0   Edit
Hardware: All All
: P4 enhancement (vote)
Target Milestone: 3.0   Edit
Assignee: Boris Bokowski CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-10-10 22:23 EDT by Darin Swanson CLA
Modified: 2005-11-07 15:49 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Darin Swanson CLA 2001-10-10 22:23:48 EDT
DS (5/1/01 2:14:44 PM)
	StructuredViewer#setSelection(ISelection, boolean) comment claims to not do call updateSelection(ISelection)
	if the selection is the same as the current selection.
	Appears to not be true from reviewing the code and from the selection changed callbacks that are occurring.
	Comment out of date or implementation oversight?

NE (5/2/01 11:14:35 PM)
	Some code is relying on this to update viewer selection and notify listeners when table selection is tweaked,
	by doing v.setSelection(v.getSelection()).
	Should find better way of doing this, and make this match the spec.
	Is this causing problems elsewhere?

DS (5/3/2001 3:05:12 PM)
	We have overridden the method so that we are not doing spurious updating on "selection"
	of the same selection.  A fix would just remove the need for our code.

NE (5/3/01 4:16:10 PM)
	I'm curious as to the use case that was causing problems.  
	Who sends setSelection often enough with the same selection to make it worth filtering out duplicates?

NE (5/3/01 4:57:43 PM)
	DS replies:
Rapidly stepping in the same stack frame. 
The thread is started and stopped and we ensure that the top stack frame is selected and revealed.
Comment 1 Kevin Haaland CLA 2002-02-01 10:58:23 EST
Making the javadoc clearer is the safest change. 
Comment 2 Kevin Haaland CLA 2003-02-07 15:17:09 EST
There are no plans for the UI team to work on this defect until higher priority 
items are addressed. 
Comment 3 Boris Bokowski CLA 2005-11-07 15:49:31 EST
The Javadoc no longer promises not to call updateSelection() if the selection is
unchanged. This was "fixed" for 3.0.