dont leave non-submenu items selected when the mouse isnt over them
This commit is contained in:
parent
e1a618444e
commit
1767616825
1 changed files with 10 additions and 0 deletions
|
@ -1181,6 +1181,16 @@ static void event_handle_menu(XEvent *ev)
|
||||||
ev->xmotion.y_root)))
|
ev->xmotion.y_root)))
|
||||||
menu_frame_select(f, e);
|
menu_frame_select(f, e);
|
||||||
}
|
}
|
||||||
|
{
|
||||||
|
ObMenuFrame *a;
|
||||||
|
|
||||||
|
a = find_active_menu();
|
||||||
|
if (a && a != f &&
|
||||||
|
a->selected->entry->type != OB_MENU_ENTRY_TYPE_SUBMENU)
|
||||||
|
{
|
||||||
|
menu_frame_select(a, NULL);
|
||||||
|
}
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case KeyPress:
|
case KeyPress:
|
||||||
if (ev->xkey.keycode == ob_keycode(OB_KEY_ESCAPE))
|
if (ev->xkey.keycode == ob_keycode(OB_KEY_ESCAPE))
|
||||||
|
|
Loading…
Reference in a new issue