1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-25 07:32:36 +01:00

wmiv: use W_KeycodeToKeysym instead of XkbKeycodeToKeysym

This patch replaces XkbKeycodeToKeysym in wmiv by our
own function W_KeycodeToKeysym.
This commit is contained in:
David
2023-02-28 10:58:10 +08:00
committed by Carlos R. Mafra
parent 9f8dc6f5dc
commit 7b317a5fba
2 changed files with 8 additions and 6 deletions

View File

@@ -70,10 +70,13 @@ wmmenugen_SOURCES = wmmenugen.c wmmenugen.h wmmenugen_misc.c \
wmmenugen_parse_wmconfig.c \
wmmenugen_parse_xdg.c
wmiv_CFLAGS = @PANGO_CFLAGS@ @PTHREAD_CFLAGS@
wmiv_LDADD = \
$(top_builddir)/wrlib/libwraster.la \
@XLFLAGS@ @XLIBS@ \
@GFXLIBS@ $(PTHREAD_CFLAGS) $(PTHREAD_LIBS) $(LIBEXIF)
$(top_builddir)/WINGs/libWINGs.la \
@XLFLAGS@ @XLIBS@ @GFXLIBS@ \
@PANGO_LIBS@ @PTHREAD_LIBS@ @LIBEXIF@
wmiv_SOURCES = wmiv.c wmiv.h

View File

@@ -22,11 +22,10 @@
#define _GNU_SOURCE
#endif
#include <X11/keysym.h>
#include <X11/XKBlib.h>
#include <X11/Xatom.h>
#include <X11/Xlib.h>
#include "wraster.h"
#include <WINGs/WINGsP.h>
#include <wraster.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
@@ -932,7 +931,7 @@ int main(int argc, char **argv)
continue;
}
if (e.type == KeyPress) {
keysym = XkbKeycodeToKeysym(dpy, e.xkey.keycode, 0, e.xkey.state & ShiftMask?1:0);
keysym = W_KeycodeToKeysym(dpy, e.xkey.keycode, e.xkey.state & ShiftMask?1:0);
#ifdef HAVE_PTHREAD
if (keysym != XK_Right)
diaporama_flag = False;