| Summary: | Close/Close Others/Close All menu in editor | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] e4 | Reporter: | Susan McCourt <susan> | ||||||||||
| Component: | UI | Assignee: | Oleg Besedin <ob1.eclipse> | ||||||||||
| Status: | VERIFIED FIXED | QA Contact: | |||||||||||
| Severity: | normal | ||||||||||||
| Priority: | P3 | CC: | bokowski, daniel_megert, emoffatt, gheorghe, ob1.eclipse, remy.suen | ||||||||||
| Version: | 1.0 | ||||||||||||
| Target Milestone: | 1.0 RC2 | ||||||||||||
| Hardware: | PC | ||||||||||||
| OS: | Windows 7 | ||||||||||||
| Whiteboard: | |||||||||||||
| Attachments: |
|
||||||||||||
|
Description
Susan McCourt
Created attachment 174510 [details]
Patch
Eric, could you review the patch?
Oleg, I haven't examined the patch itself yet but I see an NPE... Open a few editors, use 'Close' on an editor that is *not* the active one then try Close All... Created attachment 174520 [details]
Patch 2
Good point. I changed code to always get part service from the stack's context.
(In reply to comment #3) > Good point. I changed code to always get part service from the stack's context. Your second patch is getting the part service from the _application's_ context. I feel like this will cause problems (remember bug 315270 comment 36? :)). (In reply to comment #4) > (In reply to comment #3) > > Good point. I changed code to always get part service from the stack's context. > Your second patch is getting the part service from the _application's_ context. > I feel like this will cause problems (remember bug 315270 comment 36? :)). Hmm... So, is there a good way to get THE context to get part service? Other than walking up EMF tree looking for perspective / workbench window / application ? Created attachment 174524 [details]
Patch 3
Remy suggested to use AbstractPartRenderer.getContextForParent(MUIElement); seems to be working for me.
Created attachment 174525 [details]
Patch 4
Previous patch did not have all the files.
Patch applied to CVS Head. good one, I did test it on Friday but didn't hit the 'commit' for the comment saying it looked fine to me..;-). Verified in SDK 4.0 - I20100718-2237. |