1 | static void registerTab(JFrame frame, O r) { |
2 | S name = "Tab"; |
3 | Action action = abstractAction(name, r); |
4 | JComponent pnl = frame.getRootPane(); |
5 | KeyStroke keyStroke = KeyStroke.getKeyStroke(KeyEvent.VK_TAB, 0); |
6 | pnl.getActionMap().put(name, action); |
7 | pnl.getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW).put(keyStroke, name); |
8 | } |
Began life as a copy of #1003691
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1016821 |
Snippet name: | registerTab - register tab key for a whole JFrame (doesn't work) |
Eternal ID of this version: | #1016821/4 |
Text MD5: | 5c0429e10059dfa36ab02dee1b1a030a |
Author: | stefan |
Category: | javax / gui |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-07-03 15:36:27 |
Source code size: | 337 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 349 / 392 |
Version history: | 3 change(s) |
Referenced in: | [show references] |