Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CLOSED] Implement modality of a JS dialog in app shell by using a new api. #164

Open
core-ai-bot opened this issue Aug 17, 2021 · 3 comments

Comments

@core-ai-bot
Copy link
Member

Issue by RaymondLim
Tuesday Jun 25, 2013 at 21:21 GMT
Originally opened as adobe#268


This requires another pull request on brackets repo that makes calls to the new api in dialogs.js to have it working. adobe/brackets#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 with false 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

@core-ai-bot
Copy link
Member Author

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?

@core-ai-bot
Copy link
Member Author

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.

@core-ai-bot
Copy link
Member Author

Comment by RaymondLim
Friday Jan 09, 2015 at 17:47 GMT


Closing for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant