mirror of
https://github.com/gryf/wmaker.git
synced 2026-10-06 00:50:34 +02:00
WINGs: W_KeycodeToKeysym remove unnecessary if test
min_kc value is always -1 at that point in the code, so need to test it as it's always true.
This commit is contained in:
1 parent
0b2fd6a8c8
commit
038a3588d6
1 file changed
+1
-4
@@ -226,10 +226,7 @@ KeySym W_KeycodeToKeysym(Display *display, KeyCode keycode, int index)
|
||||
KeySym *key_syms;
|
||||
KeySym ks;
|
||||
|
||||
if (min_kc == -1) {
|
||||
(void) XDisplayKeycodes(display, &min_kc, &max_kc);
|
||||
}
|
||||
|
||||
XDisplayKeycodes(display, &min_kc, &max_kc);
|
||||
if (keycode < min_kc || keycode > max_kc || index < 0) {
|
||||
return NoSymbol;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user