]> git.tdb.fi Git - libs/gui.git/commitdiff
XKeycodeToKeysym is deprecated
authorMikko Rasa <tdb@tdb.fi>
Wed, 25 Jul 2012 19:47:55 +0000 (22:47 +0300)
committerMikko Rasa <tdb@tdb.fi>
Wed, 25 Jul 2012 19:47:55 +0000 (22:47 +0300)
source/input/keyboard.cpp

index 0f4d4ab848c772efb084f14cd18953c6cb412e26..ab2f9eae3b1e18a13edfb110251cbfa1155866ca 100644 (file)
@@ -63,7 +63,7 @@ void Keyboard::input_event(const Graphics::Window::Event &event)
        case KeyPress:
        case KeyRelease:
                {
-                       KeySym keysym = XKeycodeToKeysym(window.get_display().get_private().display, event.xevent.xkey.keycode, 0);
+                       KeySym keysym = XLookupKeysym(const_cast<XKeyEvent *>(&event.xevent.xkey), 0);
                        if(keysym!=NoSymbol)
                                if(unsigned key = key_from_sys(keysym))
                                        set_button_state(key, event.xevent.type==KeyPress, true);