make 'ctrl/cmd-f' shortcut detection more cross-platform

This commit is contained in:
myk
2013-02-21 17:51:20 +00:00
parent 6788bade52
commit d05dbd7112

View File

@@ -317,7 +317,7 @@ public enum CDeckEditorUI implements CardContainer {
addSelectedCards(e.isControlDown() || e.isMetaDown(), e.isShiftDown() ? 4: 1); addSelectedCards(e.isControlDown() || e.isMetaDown(), e.isShiftDown() ? 4: 1);
} else if (KeyEvent.VK_LEFT == e.getKeyCode() || KeyEvent.VK_RIGHT == e.getKeyCode()) { } else if (KeyEvent.VK_LEFT == e.getKeyCode() || KeyEvent.VK_RIGHT == e.getKeyCode()) {
deckTable.requestFocusInWindow(); deckTable.requestFocusInWindow();
} else if (e.getKeyChar() == 'f') { } else if (KeyEvent.VK_F == e.getKeyCode()) {
// let ctrl/cmd-F set focus to the text filter box // let ctrl/cmd-F set focus to the text filter box
if (e.isControlDown() || e.isMetaDown()) { if (e.isControlDown() || e.isMetaDown()) {
VCardCatalog.SINGLETON_INSTANCE.getTxfSearch().requestFocusInWindow(); VCardCatalog.SINGLETON_INSTANCE.getTxfSearch().requestFocusInWindow();