Browse Source

Keymapper: fix actions being triggered while the chatbox is open

pull/2095/head
Jmgr 5 years ago committed by Anders Jenbo
parent
commit
5c6d778af1
  1. 6
      Source/controls/keymapper.cpp

6
Source/controls/keymapper.cpp

@ -9,6 +9,7 @@
#include "utils/sdl2_to_1_2_backports.h"
#endif
#include "../control.h"
#include "../miniwin/miniwin.h"
#include "utils/log.hpp"
@ -51,8 +52,9 @@ void Keymapper::keyPressed(int key) const
auto &action = it->second;
// Some actions cannot always be triggered.
if (!action.get().enable())
// Check that the action can be triggered and that the chat textbox is not
// open.
if (!action.get().enable() || talkflag)
return;
action();

Loading…
Cancel
Save