Inotify: Reload keyboard shortcut definitions when configuration changes
commitcbe2f4e61a12b6bb13469f1eac7df14bbf423128
authorCarlos R. Mafra <crmafra@gmail.com>
Sun, 22 Jan 2012 16:11:04 +0000 (22 16:11 +0000)
committerCarlos R. Mafra <crmafra@gmail.com>
Sun, 22 Jan 2012 16:42:31 +0000 (22 16:42 +0000)
treeb3ba2b903d5f54fea7dd79cb9209efbb7de57b6a
parentc33455fdb4763391cd88ee124e138b118306403f
Inotify: Reload keyboard shortcut definitions when configuration changes

Despite having the inotify mechanism compiled in my WM, everytime I
changed a keyboard shortcut definition in the WMRootMenu via WPrefs
I was required to open the WMRootMenu (eg with the F12 key) for the
change to take effect...annoying.

So explicitly reload the key bindings when a modification inside
~/GNUstep/Defaults/ is detected. As the inotify mechanism calls the
function wDefaultsCheckDomains() when that happens, let's add a call
to rebind_key_grabs() in there.

Now it works fine and changes are automatically in effect once WPrefs
writes the menu.

PS: rebindKeygrabs() renamed to rebind_key_grabs()...
src/defaults.c
src/rootmenu.c
src/rootmenu.h