replace XKeycodeToKeysym() with XkbKeycodeToKeysym()

The XKeycodeToKeysym() is deprecated.

References: http://comments.gmane.org/gmane.comp.misc.suckless/9403
This commit is contained in:
Sami Kerola 2012-12-30 19:15:40 +00:00 committed by Mathias Gumz
parent 1804678cbe
commit 1f89a19cfc

View file

@ -23,6 +23,7 @@
#include "App.hh" #include "App.hh"
#include <X11/keysym.h> #include <X11/keysym.h>
#include <X11/XKBlib.h>
#include <string> #include <string>
#ifdef HAVE_CSTRING #ifdef HAVE_CSTRING
@ -96,8 +97,8 @@ void KeyUtil::loadModmap() {
if (m_modmap->modifiermap[realkey] == 0) if (m_modmap->modifiermap[realkey] == 0)
continue; continue;
KeySym ks = XKeycodeToKeysym(App::instance()->display(), KeySym ks = XkbKeycodeToKeysym(App::instance()->display(),
m_modmap->modifiermap[realkey], 0); m_modmap->modifiermap[realkey], 0, 0);
switch (ks) { switch (ks) {
// we just want to clean the Lock modifier, not specifically the // we just want to clean the Lock modifier, not specifically the