Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 342994 - @GroupUpdates on selection only seems to work on the first workbench window
Summary: @GroupUpdates on selection only seems to work on the first workbench window
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Runtime (show other bugs)
Version: 4.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 4.2 M1   Edit
Assignee: Oleg Besedin CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-04-15 11:31 EDT by Remy Suen CLA
Modified: 2011-06-24 09:48 EDT (History)
1 user (show)

See Also:


Attachments
SelectionService patch v1 (1.54 KB, patch)
2011-04-15 11:32 EDT, Remy Suen CLA
no flags Details | Diff
Patch (1.50 KB, patch)
2011-06-16 17:47 EDT, 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 Remy Suen CLA 2011-04-15 11:31:15 EDT
If I try to use @GroupUpdates to inject the active selection, it only ever seems to work on the first workbench window. If I spawn another workbench window that one's @GroupUpdates method does not get called.
Comment 1 Remy Suen CLA 2011-04-15 11:32:32 EDT
Created attachment 193384 [details]
SelectionService patch v1

1. Launch an inner with the patch applied to SelectionService (should apply cleanly to v1.20).
2. Select stuff in the 'Problems' view, both @Inject methods are being called.
3. Window > New Window
4. Repeat step 2 for this new workbench window. The @GroupUpdates method does not get called.
Comment 2 Oleg Besedin CLA 2011-06-16 17:47:08 EDT
Created attachment 198152 [details]
Patch

Seems to be a side effect of an uninject event for a different object on the same context.
Comment 3 Remy Suen CLA 2011-06-17 10:34:26 EDT
(In reply to comment #2)
> Seems to be a side effect of an uninject event for a different object on the
> same context.

It sounds like this bug would happen even for cases where @GroupUpdates is not used then, is this correct?
Comment 4 Oleg Besedin CLA 2011-06-17 10:56:31 EDT
(In reply to comment #3)
> It sounds like this bug would happen even for cases where @GroupUpdates is not
> used then, is this correct?

No, I don't think so. The problem is in setting "cachedEvent" type to null while, in reality, the event has not being processed. The "cachedEvent" is only used for grouped updates.
Comment 5 Oleg Besedin CLA 2011-06-24 09:48:03 EDT
Patch applied to CVS Head.