1 --- trunk.orig/etc/cfg_menu.lua
2 +++ trunk/etc/cfg_menu.lua
6 bdoc("Close the menu."),
7 - kpress("Escape", "WMenu.cancel(_)"),
8 + kpress("Escape", "WMenu.cancel(_)", nil, true),
9 kpress("Control+G", "WMenu.cancel(_)"),
10 kpress("Control+C", "WMenu.cancel(_)"),
11 kpress("Left", "WMenu.cancel(_)"),
13 bdoc("Activate current menu entry."),
14 kpress("Return", "WMenu.finish(_)"),
15 - kpress("KP_Enter", "WMenu.finish(_)"),
16 + kpress("KP_Enter", "WMenu.finish(_)", nil, true),
17 kpress("Control+M", "WMenu.finish(_)"),
18 kpress("Right", "WMenu.finish(_)"),
20 --- trunk.orig/etc/cfg_query.lua
21 +++ trunk/etc/cfg_query.lua
23 bdoc("Go to end/beginning."),
24 kpress("Control+E", "WEdln.eol(_)"),
25 kpress("Control+A", "WEdln.bol(_)"),
26 - kpress("End", "WEdln.eol(_)"),
27 - kpress("Home", "WEdln.bol(_)"),
28 + kpress("End", "WEdln.eol(_)", nil, true),
29 + kpress("Home", "WEdln.bol(_)", nil, true),
31 bdoc("Skip one word forward/backward."),
32 kpress("Control+X", "WEdln.skip_word(_)"),
35 bdoc("Delete next character."),
36 kpress("Control+D", "WEdln.delete(_)"),
37 - kpress("Delete", "WEdln.delete(_)"),
38 + kpress("Delete", "WEdln.delete(_)", nil, true),
40 bdoc("Delete previous character."),
41 kpress("BackSpace", "WEdln.backspace(_)"),
43 bdoc("Close the query and execute bound action."),
44 kpress("Control+M", "WEdln.finish(_)"),
45 kpress("Return", "WEdln.finish(_)"),
46 - kpress("KP_Enter", "WEdln.finish(_)"),
47 + kpress("KP_Enter", "WEdln.finish(_)", nil, true),
51 defbindings("WInput", {
52 bdoc("Close the query/message box, not executing bound actions."),
53 - kpress("Escape", "WInput.cancel(_)"),
54 + kpress("Escape", "WInput.cancel(_)", nil, true),
55 kpress("Control+G", "WInput.cancel(_)"),
56 kpress("Control+C", "WInput.cancel(_)"),
58 bdoc("Scroll the message or completions up/down."),
59 kpress("Control+U", "WInput.scrollup(_)"),
60 kpress("Control+V", "WInput.scrolldown(_)"),
61 - kpress("Page_Up", "WInput.scrollup(_)"),
62 - kpress("Page_Down", "WInput.scrolldown(_)"),
63 + kpress("Page_Up", "WInput.scrollup(_)", nil, true),
64 + kpress("Page_Down", "WInput.scrolldown(_)", nil, true),
68 --- trunk.orig/ioncore/conf-bindings.c
69 +++ trunk/ioncore/conf-bindings.c
73 bool ioncore_parse_keybut(const char *str, uint *mod_ret, uint *ksb_ret,
74 - bool button, bool init_any)
75 + bool button, bool init_any, bool quiet_absent)
78 int keysym=NoSymbol, i;
82 if(XKeysymToKeycode(ioncore_g.dpy, keysym)==0){
83 - warn_obj(str, TR("Could not convert keysym to keycode."));
85 + warn_obj(str, TR("Could not convert keysym to keycode."));
95 if(!extl_table_gets_s(tab, "action", &action_str)){
96 warn(TR("Binding type not set."));
98 if(!extl_table_gets_s(tab, "kcb", &ksb_str))
101 + if(!extl_table_gets_b(tab, "extra", &extra))
104 if(!ioncore_parse_keybut(ksb_str, &mod, &ksb,
105 (action!=BINDING_KEYPRESS && action!=-1),
111 --- trunk.orig/ioncore/ioncore_bindings.lua
112 +++ trunk/ioncore/ioncore_bindings.lua
114 -- Creates a binding description table for the action of pressing a key given
115 -- by \var{keyspec} (with possible modifiers) to the function \var{cmd}.
116 -- The \var{guard} controls when the binding can be called.
117 +-- The \var{extra} flag signals whether the binding is a non-critical extra
118 +-- binding. If this is true and a named key does not exist, the binding will
119 +-- be quietly ignored.
120 -- For more informationp see Section \ref{sec:bindings}.
121 -function ioncore.kpress(keyspec, cmd, guard)
122 - return putcmd(cmd, guard, {action = "kpress", kcb = keyspec})
123 +function ioncore.kpress(keyspec, cmd, guard, extra)
124 + return putcmd(cmd, guard, {action = "kpress", kcb = keyspec, extra = extra})
128 --- trunk.orig/ioncore/conf-bindings.h
129 +++ trunk/ioncore/conf-bindings.h
132 extern bool ioncore_parse_keybut(const char *str,
133 uint *mod_ret, uint *ksb_ret,
134 - bool button, bool init_any);
135 + bool button, bool init_any, bool quiet_absent);
137 #endif /* ION_IONCORE_CONF_BINDINGS_H */
138 --- trunk.orig/etc/cfg_ioncore.lua
139 +++ trunk/etc/cfg_ioncore.lua
142 defbindings("WMoveresMode", {
143 bdoc("Cancel the resize mode."),
144 - kpress("AnyModifier+Escape","WMoveresMode.cancel(_)"),
145 + kpress("AnyModifier+Escape","WMoveresMode.cancel(_)", nil, true),
147 bdoc("End the resize mode."),
148 kpress("AnyModifier+Return","WMoveresMode.finish(_)"),