X-Git-Url: https://git.brokenzipper.com/gitweb?a=blobdiff_plain;f=openbox%2Fmenuframe.h;h=62df87ca3263b5a8a9f8200db96e569e7cc2a5b2;hb=8968b38338529cd0a7f2ad08a7c2e0d2e76b6e62;hp=e1f4b15bfe03b4ddd3b355f883731e5b1ffcbf99;hpb=83da4ec9398d197f39461cd7305163b2676840c8;p=chaz%2Fopenbox diff --git a/openbox/menuframe.h b/openbox/menuframe.h index e1f4b15b..62df87ca 100644 --- a/openbox/menuframe.h +++ b/openbox/menuframe.h @@ -71,15 +71,22 @@ struct _ObMenuFrame gint monitor; /* monitor on which to show the menu in xinerama */ - RrAppearance *a_title; + /* We make a copy of this for each menu, so that we don't have to re-render + the background of the entire menu each time we render an item inside it. + */ RrAppearance *a_items; + + gboolean got_press; /* don't allow a KeyRelease event to run things in the + menu until it has seen a KeyPress. this is to + avoid having the keybinding used to show the menu + end up running something inside the menu */ + ObMenuEntryFrame * submenu_to_hide; /* if exist (single!) submenu hide request + then this variable hold a copy of 'selected' field of the parent menu, + otherwice NULL */ }; struct _ObMenuEntryFrame { - /* if this is true then it doesn't have an entry to point to */ - gboolean more; - struct _ObMenuEntry *entry; ObMenuFrame *frame; @@ -92,22 +99,6 @@ struct _ObMenuEntryFrame Window icon; Window text; Window bullet; - - RrAppearance *a_normal; - RrAppearance *a_selected; - RrAppearance *a_disabled; - RrAppearance *a_disabled_selected; - - RrAppearance *a_icon; - RrAppearance *a_mask; - RrAppearance *a_bullet_normal; - RrAppearance *a_bullet_selected; - RrAppearance *a_separator; - RrAppearance *a_text_normal; - RrAppearance *a_text_selected; - RrAppearance *a_text_disabled; - RrAppearance *a_text_disabled_selected; - RrAppearance *a_text_title; }; extern GHashTable *menu_frame_map; @@ -144,6 +135,6 @@ ObMenuEntryFrame* menu_entry_frame_under(gint x, gint y); void menu_entry_frame_show_submenu(ObMenuEntryFrame *self); -void menu_entry_frame_execute(ObMenuEntryFrame *self, guint state, Time time); +void menu_entry_frame_execute(ObMenuEntryFrame *self, guint state); #endif