Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 338953 - [Compatibility] 'Close All' should always be enabled when editors are open
Summary: [Compatibility] 'Close All' should always be enabled when editors are open
Status: VERIFIED FIXED
Alias: None
Product: e4
Classification: Eclipse Project
Component: UI (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 4.1 M6   Edit
Assignee: Remy Suen CLA
QA Contact: Remy Suen CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-04 11:07 EST by Grant Gayed CLA
Modified: 2011-03-08 11:45 EST (History)
1 user (show)

See Also:


Attachments
'Close All' patch v1 (3.18 KB, patch)
2011-03-04 14:35 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 Grant Gayed CLA 2011-03-04 11:07:34 EST
- using I20110225-1300

- open two java editors
- File > Restart
- when the UI comes up again the two previously opened editors are auto-opened, but menu item File > Close All only becomes enabled when focus is given to an editor
  -> for File > Close this makes sense, but doesn't seem like it should be a requirement for File > Close All
Comment 1 Remy Suen CLA 2011-03-04 14:10:29 EST
While the scenario described in comment 0 has been fixed with the closing of bug 306952, this problem can still surface in 4.x because this handler seems to only be enabled when we have an active editor. This is no longer a valid assessment because we you have an editor opened but it is obscured by another part (hence there isn't an active editor).
Comment 2 Remy Suen CLA 2011-03-04 14:35:19 EST
Created attachment 190433 [details]
'Close All' patch v1

Change the XML <enabledWhen> expression to not refer to the 'activeEditor' variable and alter CloseAllHandler internally to check for editor references in the workbench page.
Comment 3 Remy Suen CLA 2011-03-04 14:37:42 EST
(In reply to comment #2)
> Created attachment 190433 [details]
> 'Close All' patch v1

Patch released to CVS HEAD.

Thanks for the bug report, Grant!
Comment 4 Remy Suen CLA 2011-03-08 11:45:44 EST
Verified with I20110307-2200 on Windows XP.