GNOME Bugzilla – Bug 688462
Add more keys to unmodified keybindings "whitelist"
Last modified: 2013-02-15 16:38:39 UTC
Created attachment 229131 [details] [review] PATCH adding ScreenLock, Pause & Insert to whitelist Add keys that don't have side-effects to the unmodified keybindings' "whitelist". On my keyboard, these would be: Scroll Lock Pause Break Poblem: currently cannot bind keys like Scroll Lock without modifier. SOLUTION #1: See **attached patch** which adds the 3 keys above to the "whitelist". SOLUTION #2: Add these keys to gsd-keygrab.c file via these lines: key->keysym != GDK_KEY_Scroll_Lock && key->keysym != GDK_KEY_Pause && key->keysym != GDK_KEY_Break && To this code: if (!(flags & GSD_KEYGRAB_ALLOW_UNMODIFIED) && (modifiers & gsd_used_mods) == 0 && !IN_RANGE(key->keysym, XF86KEYS_RANGE_MIN, XF86KEYS_RANGE_MAX) && !IN_RANGE(key->keysym, FKEYS_RANGE_MIN, FKEYS_RANGE_MAX) && key->keysym != GDK_KEY_Pause && key->keysym != GDK_KEY_Print && key->keysym != GDK_KEY_Menu) { GString *keycodes; Currently that is line 171. See here: http://git.gnome.org/browse/gnome-settings-daemon/tree/plugins/common/gsd-keygrab.c#n166 ADDITIONAL SUGGESTIONS: I *highly* suggest going through the all the possible GDK keys and adding additional ones to the "white list" above. All GDK keys are listed in this file: http://git.gnome.org/browse/gtk+/plain/gdk/gdkkeysyms.h While I understand the rationale behind not allowing unmodified keys, please keep in mind that different keyboards have different keys and layouts and the way it works now is very restrictive.
Fixed in GNOME 3.7, thanks for the patch.