diff options
author | Bastien Nocera <hadess@hadess.net> | 2011-11-10 10:59:44 +0000 |
---|---|---|
committer | Bastien Nocera <hadess@hadess.net> | 2011-11-10 14:33:28 +0000 |
commit | c30d313afcc6941d8c64c83854fdd0fe33049917 (patch) | |
tree | be56bdb54d26ff76af868fd8b04eaf0d16abb355 /gtk/gtkaccelgroup.c | |
parent | d69c7f4776506efd0c66dccf7e16bb9461f040c0 (diff) | |
download | gtk+-c30d313afcc6941d8c64c83854fdd0fe33049917.tar.gz |
gtk: Fix parsing of accelerators with keycodes
GDK_KEY_VoidSymbol is not the same as keycode 0. This fixes
keycodes such as "0xb3" being parsed as "VoidSymbol" keysyms.
https://bugzilla.gnome.org/show_bug.cgi?id=663761
Diffstat (limited to 'gtk/gtkaccelgroup.c')
-rw-r--r-- | gtk/gtkaccelgroup.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/gtk/gtkaccelgroup.c b/gtk/gtkaccelgroup.c index cb31d029bd..6d30880cda 100644 --- a/gtk/gtkaccelgroup.c +++ b/gtk/gtkaccelgroup.c @@ -1323,8 +1323,6 @@ gtk_accelerator_parse_with_keycode (const gchar *accelerator, gchar *endptr; gint tmp_keycode; - keyval = GDK_KEY_VoidSymbol; - memcpy (keystring, accelerator, 4); keystring [4] = '\000'; @@ -1367,7 +1365,7 @@ gtk_accelerator_parse_with_keycode (const gchar *accelerator, } } - if (keyval != GDK_KEY_VoidSymbol && accelerator_codes != NULL) + if (keyval && accelerator_codes != NULL) { GdkKeymapKey *keys; gint n_keys, i, j; |