Fix bug handling multi-key binds
This commit is contained in:
parent
90cc7adbd2
commit
0131ab6f97
11
src/imv.c
11
src/imv.c
|
@ -415,9 +415,14 @@ static void key_handler(struct imv *imv, const struct imv_event *event)
|
|||
return;
|
||||
}
|
||||
|
||||
struct list *cmds = imv_bind_handle_event(imv->binds, event->data.keyboard.description);
|
||||
if (cmds) {
|
||||
imv_command_exec_list(imv->commands, cmds, imv);
|
||||
/* Keys such as Shift on their own come through as '', we should skip them
|
||||
* since they'll turn up later as 'Shift+W', etc.
|
||||
*/
|
||||
if (*event->data.keyboard.description != '\0') {
|
||||
struct list *cmds = imv_bind_handle_event(imv->binds, event->data.keyboard.description);
|
||||
if (cmds) {
|
||||
imv_command_exec_list(imv->commands, cmds, imv);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue