# HG changeset patch # User Sadrul Habib Chowdhury # Date 1163995533 0 # Node ID 7589733ba1aa37babaf4898ad540df87fe8af3bc # Parent a259abeeee27a5c2a418e08694694e4b69cefeda [gaim-migrate @ 17789] F10 to show the menu of a window. F11 to show the context-menu. I would've used shift+F10 if terminfo permitted. Fix a bug where F10 etc. could not be used for rebinding. committer: Tailor Script diff -r a259abeeee27 -r 7589733ba1aa console/libgnt/gntstyle.c --- a/console/libgnt/gntstyle.c Mon Nov 20 03:57:47 2006 +0000 +++ b/console/libgnt/gntstyle.c Mon Nov 20 04:05:33 2006 +0000 @@ -91,7 +91,7 @@ /* XXX: Need to do something about ctrl/alt+home, end etc. */ #define SPECIAL_KEY(k, code) do { \ - if (strncasecmp(key, k, sizeof(k) - 1) == 0) \ + if (strcasecmp(key, k) == 0) \ return g_strdup(code); \ } while (0) diff -r a259abeeee27 -r 7589733ba1aa console/libgnt/gntwidget.c --- a/console/libgnt/gntwidget.c Mon Nov 20 03:57:47 2006 +0000 +++ b/console/libgnt/gntwidget.c Mon Nov 20 04:05:33 2006 +0000 @@ -239,6 +239,7 @@ /* This is relevant for all widgets */ gnt_bindable_class_register_action(GNT_BINDABLE_CLASS(klass), "context-menu", context_menu, GNT_KEY_POPUP, NULL); + gnt_bindable_register_binding(GNT_BINDABLE_CLASS(klass), "context-menu", GNT_KEY_F11, NULL); gnt_style_read_actions(G_OBJECT_CLASS_TYPE(klass), GNT_BINDABLE_CLASS(klass)); GNTDEBUG; diff -r a259abeeee27 -r 7589733ba1aa console/libgnt/gntwindow.c --- a/console/libgnt/gntwindow.c Mon Nov 20 03:57:47 2006 +0000 +++ b/console/libgnt/gntwindow.c Mon Nov 20 04:05:33 2006 +0000 @@ -43,6 +43,7 @@ gnt_bindable_class_register_action(bindable, "show-menu", show_menu, GNT_KEY_CTRL_O, NULL); + gnt_bindable_register_binding(bindable, "show-menu", GNT_KEY_F10, NULL); gnt_style_read_actions(G_OBJECT_CLASS_TYPE(klass), bindable); GNTDEBUG;