X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Fmenuframe.c;h=2010bf8fe4289b799ff96c3d422d41ee92c4245d;hb=8adfa33f46a03b03eaf79a319dc1f59e5664a78d;hp=7bacf02068e48a9a6e45b795136a4509dcf53716;hpb=780d1b0961e2eed5fea4645b4398fafb4adad73a;p=chaz%2Fopenbox diff --git a/openbox/menuframe.c b/openbox/menuframe.c index 7bacf020..2010bf8f 100644 --- a/openbox/menuframe.c +++ b/openbox/menuframe.c @@ -401,6 +401,7 @@ static void menu_entry_frame_render(ObMenuEntryFrame *self) text_a->texture[0].data.text.string = self->entry->data.normal.label; if (self->entry->data.normal.shortcut && (self->frame->menu->show_all_shortcuts || + self->entry->data.normal.shortcut_always_show || self->entry->data.normal.shortcut_position > 0)) { text_a->texture[0].data.text.shortcut = TRUE; @@ -416,6 +417,7 @@ static void menu_entry_frame_render(ObMenuEntryFrame *self) sub = self->entry->data.submenu.submenu; text_a->texture[0].data.text.string = sub ? sub->title : ""; if (sub->shortcut && (self->frame->menu->show_all_shortcuts || + sub->shortcut_always_show || sub->shortcut_position > 0)) { text_a->texture[0].data.text.shortcut = TRUE; @@ -941,7 +943,7 @@ static gboolean menu_frame_show(ObMenuFrame *self) } gboolean menu_frame_show_topmenu(ObMenuFrame *self, gint x, gint y, - gint button) + gboolean mouse) { gint px, py; guint i; @@ -963,7 +965,7 @@ gboolean menu_frame_show_topmenu(ObMenuFrame *self, gint x, gint y, } if (self->menu->place_func) - self->menu->place_func(self, &x, &y, button, self->menu->data); + self->menu->place_func(self, &x, &y, mouse, self->menu->data); else menu_frame_place_topmenu(self, &x, &y); @@ -1179,7 +1181,7 @@ void menu_entry_frame_show_submenu(ObMenuEntryFrame *self) menu_frame_show_submenu(f, self->frame, self); } -void menu_entry_frame_execute(ObMenuEntryFrame *self, guint state, Time time) +void menu_entry_frame_execute(ObMenuEntryFrame *self, guint state) { if (self->entry->type == OB_MENU_ENTRY_TYPE_NORMAL && self->entry->data.normal.enabled) @@ -1200,11 +1202,10 @@ void menu_entry_frame_execute(ObMenuEntryFrame *self, guint state, Time time) } if (func) - func(entry, frame, client, state, data, time); + func(entry, frame, client, state, data); else actions_run_acts(acts, OB_USER_ACTION_MENU_SELECTION, - time, state, -1, -1, OB_FRAME_CONTEXT_NONE, - client); + state, -1, -1, 0, OB_FRAME_CONTEXT_NONE, client); } }