maybe this makes everyone happy, only select first entry in menus if it's not a submenu entry
This commit is contained in:
parent
310d268bf0
commit
5648f0d75c
1 changed files with 6 additions and 2 deletions
|
@ -315,8 +315,12 @@ void menu_show(gchar *name, gint x, gint y, ObClient *client)
|
|||
}
|
||||
if (!menu_frame_show(frame, NULL))
|
||||
menu_frame_free(frame);
|
||||
else if (frame->entries)
|
||||
menu_frame_select_next(frame);
|
||||
else if (frame->entries) {
|
||||
ObMenuEntryFrame *e = frame->entries->data;
|
||||
if (e->entry->type == OB_MENU_ENTRY_TYPE_NORMAL &&
|
||||
e->entry->data.normal.enabled)
|
||||
menu_frame_select(frame, e);
|
||||
}
|
||||
}
|
||||
|
||||
static ObMenuEntry* menu_entry_new(ObMenu *menu, ObMenuEntryType type, gint id)
|
||||
|
|
Loading…
Reference in a new issue