1
0
mirror of https://github.com/gryf/wmaker.git synced 2026-01-07 22:34:18 +01:00

WPrefs: XKeycodeToKeysym deprecated function

The function XKeycodeToKeysym is deprecated and should be replaced
by XkbKeycodeToKeysym.
This commit is contained in:
Rodolfo García Peñas (kix)
2012-07-15 10:54:44 +02:00
committed by Carlos R. Mafra
parent 139f912e61
commit 43c3526d21
3 changed files with 6 additions and 3 deletions

View File

@@ -25,6 +25,7 @@
#include <ctype.h>
#include <X11/keysym.h>
#include <X11/XKBlib.h>
typedef struct _Panel {
WMBox *box;
@@ -242,7 +243,7 @@ char *capture_shortcut(Display *dpy, Bool *capturing, Bool convert_case)
XAllowEvents(dpy, AsyncKeyboard, CurrentTime);
WMNextEvent(dpy, &ev);
if (ev.type == KeyPress && ev.xkey.keycode != 0) {
ksym = XKeycodeToKeysym(dpy, ev.xkey.keycode, 0);
ksym = XkbKeycodeToKeysym(dpy, ev.xkey.keycode, 0, 0);
if (!IsModifierKey(ksym)) {
if (convert_case) {
XConvertCase(ksym, &lksym, &uksym);