A software engineer, somewhere, needs to have their abstraction taken away. Who crafts the sort of API that would require a five-line helper function just to set the shortcut key for a menu item?
(String title, int what)
| 177 | * menu item? |
| 178 | */ |
| 179 | static public JMenuItem newJMenuItem(String title, int what) { |
| 180 | JMenuItem menuItem = new JMenuItem(title); |
| 181 | menuItem.setAccelerator(KeyStroke.getKeyStroke(what, SHORTCUT_KEY_MASK)); |
| 182 | return menuItem; |
| 183 | } |
| 184 | |
| 185 | |
| 186 | /** |
no outgoing calls
no test coverage detected