projects
/
tilda-gobject.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f9193eb
)
[Keybinder] Add better validation
author
Ira W. Snyder
<devel@irasnyder.com>
Tue, 29 Jan 2008 20:16:41 +0000
(12:16 -0800)
committer
Ira W. Snyder
<devel@irasnyder.com>
Tue, 29 Jan 2008 20:16:41 +0000
(12:16 -0800)
The GTK+ documentation for gtk_accelerator_parse() is incorrect, so
use the gtk_accelerator_valid() function to check if accelerators are
invalid instead of following the documentation.
tomboykeybinder.c
patch
|
blob
|
history
diff --git
a/tomboykeybinder.c
b/tomboykeybinder.c
index
d88daa3
..
f2854e9
100644
(file)
--- a/
tomboykeybinder.c
+++ b/
tomboykeybinder.c
@@
-96,7
+96,7
@@
do_grab_key (Binding *binding)
gtk_accelerator_parse (binding->keystring, &keysym, &virtual_mods);
- if (
keysym == 0 && virtual_mods == 0
)
+ if (
!gtk_accelerator_valid(keysym, virtual_mods)
)
return FALSE;
TRACE (g_print ("Got accel %d, %d\n", keysym, virtual_mods));