| Summary: | Investigate ways to simplify the definition / customization of menus / toolbars | ||
|---|---|---|---|
| Product: | [ECD] Orion | Reporter: | Eric Moffatt <emoffatt> |
| Component: | Client | Assignee: | Eric Moffatt <emoffatt> |
| Status: | CLOSED WONTFIX | QA Contact: | |
| Severity: | enhancement | ||
| Priority: | P3 | CC: | libingw, snorthov |
| Version: | 12.0 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows 7 | ||
| Whiteboard: | |||
| Bug Depends on: | |||
| Bug Blocks: | 457886 | ||
|
Description
Eric Moffatt
org.eclipse.orion.client.ui/web/embeddedEditor/demo/demoCodeEdit.html will be something we can start with. I t consumes the non built version of the widget and I've already creates a separate DIV ,trying to render all the commands. Also, we should think about the editor context menu as well. OK, I've just pushed (into the 'MenuStructs' branch) code that: 1) removes any need to have a 'handler' defined in the menu structure (meaning it's JSON'able again). 2) greatly simplify all 'visibleWhen' and 'callback' methods for editor commands to never reference the 'data.handler' field (visibleWhen impls) or 'this' (callback impls). I've checked to ensure that the result correctly handles multi-editor cases (including GIT diffs) to ensure that we haven't regressed anything. Libing, next week we should work out how to allow Edit Code to hook into the new mechanism... OK, I've updated the 'MenuStructs' branch... At this point everything has been switched over to using the menu structure for each of the Edit / Git & Compare pages with the following exceptions: GlobalCommands are handled by a local change in the file that defines its 'struct' OperationsDialog defines its own 'cancel' operation (TBD) Git Page: CompareCommands#197: has 'toggleCommandSpanId' (move to the specific menu structs git vs compare ?) resourceComparer#264 Save command needs handler Compare Page: CompareCommands#197: does *not* have 'toggleCommandSpanId' (move to the specific menu structs git vs compare ?) Save command still handled the old way because it needs a handler (change visibleWhen / order of creation to match the Git page (where the simplified visibleWhen works correctly. Edit Page: Tools Menu Extensions...EditorCommands#318... Editor Context Menu Extensions...editorCommands#362 sidebar registers the 'propblemsInFolder' command (Twice) (move to 'toolsActions' struct) setup@1093 registers 'splitMode' to 'settingsActions' common-nav#375 OpenWith, FileCommands and new ProjectCommands extensions filesystemSwitcher#77 registers a mini-nav "orion.nav.switchfs" outliner#528 registers "Sourece Outliner" to viewActions at "orion.menuBarViewGroup/orion.slideoutMenuGroup" Eric, you worked on this a while back. Did the changes ever get in? We (as a group) need to decide whether we are better off with the code or without it. The final word is a Silenio/Steve decision and we just need to make it once we have the information. Closing as part of a mass clean up of inactive bugs. Please reopen if this problem still occurs or is relevant to you. For more details see: https://dev.eclipse.org/mhonarc/lists/orion-dev/msg04114.html |