diff --git a/ChangeLog b/ChangeLog index 67ee11d6..bc9f25a0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ (Format: Year/Month/Day) Changes for 1.1.2 +*08/11/01: + * Don't reload keys file when modifier map changes, just regrab (Mark) + Keys.cc/hh fluxbox.cc *08/10/15: * Don't allow resizing to negative dimensions (Mathias) Window.cc/hh diff --git a/src/Keys.cc b/src/Keys.cc index 658820e1..ac255888 100644 --- a/src/Keys.cc +++ b/src/Keys.cc @@ -571,6 +571,10 @@ void Keys::reconfigure() { m_reloader->checkReload(); } +void Keys::regrab() { + setKeyMode(m_keylist); +} + void Keys::keyMode(const string& keyMode) { keyspace_t::iterator it = m_map.find(keyMode + ":"); if (it == m_map.end()) diff --git a/src/Keys.hh b/src/Keys.hh index 9502643c..af64a1d6 100644 --- a/src/Keys.hh +++ b/src/Keys.hh @@ -73,6 +73,9 @@ public: /// unregister window void unregisterWindow(Window win); + /// grab keys again when keymap changes + void regrab(); + const std::string& filename() const { return m_filename; } /** Load configuration from file diff --git a/src/fluxbox.cc b/src/fluxbox.cc index 706556c6..93768dac 100644 --- a/src/fluxbox.cc +++ b/src/fluxbox.cc @@ -772,7 +772,7 @@ void Fluxbox::handleEvent(XEvent * const e) { XRefreshKeyboardMapping(&e->xmapping); FbTk::KeyUtil::instance().init(); // reinitialise the key utils // reconfigure keys (if the mapping changes, they don't otherwise update - m_key->reload(); + m_key->regrab(); } break; case CreateNotify: