Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 331668 - ESelectionService should not notify listeners if the active part does not post selections
Summary: ESelectionService should not notify listeners if the active part does not pos...
Status: RESOLVED FIXED
Alias: None
Product: e4
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 1.0   Edit
Hardware: All All
: P3 major (vote)
Target Milestone: 4.1 M4   Edit
Assignee: Remy Suen CLA
QA Contact: Remy Suen CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-12-02 09:09 EST by Remy Suen CLA
Modified: 2010-12-04 03:46 EST (History)
2 users (show)

See Also:


Attachments
SelectionService patch v1 (1.14 KB, patch)
2010-12-02 09:11 EST, Remy Suen CLA
no flags Details | Diff
SelectionService patch v2 (2.06 KB, patch)
2010-12-02 09:22 EST, Remy Suen CLA
no flags Details | Diff
ESelectionService patch v1 (2.21 KB, patch)
2010-12-02 13:26 EST, Remy Suen CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Remy Suen CLA 2010-12-02 09:09:30 EST
Even if you do not set a selection provider for your IWorkbenchPart implementation, we are still propagating selection events for that part within the given workbench window.
Comment 1 Remy Suen CLA 2010-12-02 09:11:13 EST
Created attachment 184351 [details]
SelectionService patch v1

We should ignore selection events from parts that haven't registered a selection provider.
Comment 2 Remy Suen CLA 2010-12-02 09:22:20 EST
Created attachment 184352 [details]
SelectionService patch v2

Actually, we should be preventing ISources.ACTIVE_CURRENT_SELECTION from changing also.
Comment 3 Remy Suen CLA 2010-12-02 13:26:19 EST
Created attachment 184376 [details]
ESelectionService patch v1

The ESS should only send out notifications if the part actually posts selections.
Comment 4 Remy Suen CLA 2010-12-02 13:27:38 EST
Fix delivered to HEAD. Thank you very much for the bug report, Thomas!
Comment 5 Thomas Kratz CLA 2010-12-04 03:46:10 EST
Thanks Remy, works like a charm now