This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Esc key should focus Editor | ||
---|---|---|---|
Product: | platform | Reporter: | David Simonek <dsimonek> |
Component: | Window System | Assignee: | issues@platform <issues> |
Status: | NEW --- | ||
Severity: | blocker | CC: | tboudreau |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | ENHANCEMENT | Exception Reporter: |
Description
David Simonek
2006-07-20 18:19:59 UTC
Btw, patch would be welcomed. Only fully working! :-) In a smaller project with similar popups, I just did something like this: getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW).put( KeyStroke.getKeyStroke(KeyEvent.VK_ESCAPE, 0), "hidePopup"); //NOI18N getActionMap().put ("hidePopup", popupComponentManager); //NOI18N where popupComponentManager.hide() gets called whenever esc is pressed - if something else has already consumed the key event, it shouldn't be triggered. Can't guarantee it will work given the weird stuff we do with actionmaps & such, but it might just work fine. |