Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 369447 - Simplify selection service implementation
Summary: Simplify selection service implementation
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 4.2   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 4.2 M6   Edit
Assignee: Oleg Besedin CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-23 15:40 EST by Oleg Besedin CLA
Modified: 2012-03-13 13:44 EDT (History)
4 users (show)

See Also:


Attachments
Patch (48.39 KB, patch)
2012-01-23 15:54 EST, Oleg Besedin CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Oleg Besedin CLA 2012-01-23 15:40:38 EST
The selection service implementation has grown to be a rather complicated combination of DS, creation functions, trackers, and computed functions. This creates problems in CPU performance and debugging.
Comment 1 Oleg Besedin CLA 2012-01-23 15:54:01 EST
Created attachment 209938 [details]
Patch

Patch to be applied once M6 starts.

Changes:

gone:
	SelectionLookupFunction
	SelectionServiceCreationFunction
	ApplicationSelectionServiceImpl
	PartSelectionServiceImpl
	ESelectionService.SELECTION (API, deprecated) (use IServiceConstants.ACTIVE_SELECTION)

added:
	SelectionAggregator (this is what SelectionServiceImpl used to be)
	E4Application#initializeServices() - place to initialize services we need in app & window contexts, potential API
		
	
changed:
	SelectionServiceImpl - now a wrapper that remembers its context and delegates everything to SelectionAggregator
Comment 2 Oleg Besedin CLA 2012-01-31 10:06:22 EST
Remy found a problem when closing 2nd workbench window, this should fix it:

http://git.eclipse.org/c/platform/eclipse.platform.ui.git/commit/?id=2e7be1c5681fb49132e593d4072a42d5eff8db7e
Comment 3 Oleg Besedin CLA 2012-01-31 10:39:36 EST
.
Comment 4 Oleg Besedin CLA 2012-03-13 13:44:41 EDT
Verified that code is present in the I20120313-0610.