Open core-ai-bot opened 3 years ago
Comment by quasado Monday Dec 09, 2013 at 17:02 GMT
I am curious whether this pull request will ever make it into brackets-shell repo or not?
Comment by iwehrman Thursday Jan 02, 2014 at 18:24 GMT
I am also curious. We should discuss this in an architecture review meeting, if necessary. I really wish I could dismiss modal dialogs with the keyboard, and I think this is one route to a solution? Basic keyboard accessibility might something we consider important for a 1.0 release.
Issue by RaymondLim Tuesday Jun 25, 2013 at 21:21 GMT Originally opened as https://github.com/adobe/brackets-shell/pull/268
This requires another pull request on brackets repo that makes calls to the new api in dialogs.js to have it working. https://github.com/adobe/brackets/pull/4341
A new API setModal is introduced so that Brackets can tell app shell to enforce modality when a JS modal dialog is showing. Before showing the JS dialog, we need to call this api with
true
argument; and after dismissing the dialog, we need to call it withfalse
argument.When the modality is on, all menu items will be disabled and users will not be able to click on any menu item or using its shortcuts. One exception to this on Mac is that some of the Edit menu items (Undo, Redo, Cut, Copy, Paste and Select All) will still be enabled so that users can use them in text fields in any JS dialog.
Modality is not only enforced on menus and shortcuts, but also on other UIs and shortcuts available on the window title bar. That is. X button and Alt+F4 shortcut will be disabled during the display of a JS dialog.
Although menus and commands won't be available in a JS dialog, dialog-specific shortcuts or key events will be available. For example, Cmd-D, Cmd-. and Escape key to dismiss the dialog.
RaymondLim included the following code: https://github.com/adobe/brackets-shell/pull/268/commits