diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/game.cpp | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/src/game.cpp b/src/game.cpp index f264ad27..2320617c 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -629,21 +629,25 @@ void Game::handleInput() } */ } - if (keyboard.isKeyActive(keyboard.KEY_TOGGLE_CHAT)) + else if (keyboard.isKeyActive(keyboard.KEY_TOGGLE_CHAT)) { if (chatWindow->requestChatFocus()) used = true; } - if (keyboard.isKeyActive(keyboard.KEY_PREV_CHAT_TAB)) - { - chatWindow->prevTab(); - return; - } - else if (keyboard.isKeyActive(keyboard.KEY_NEXT_CHAT_TAB)) + + if (!chatWindow->isInputFocused() || (event.key.keysym.mod & KMOD_ALT)) { - chatWindow->nextTab(); - return; + if (keyboard.isKeyActive(keyboard.KEY_PREV_CHAT_TAB)) + { + chatWindow->prevTab(); + return; + } + else if (keyboard.isKeyActive(keyboard.KEY_NEXT_CHAT_TAB)) + { + chatWindow->nextTab(); + return; + } } const int tKey = keyboard.getKeyIndex(event.key.keysym.sym); |