- /* If the menu is currently displayed */
- gboolean shown;
-
- /* If the rendering of the menu has changed and needs to be rerendered. */
- gboolean invalid;
-
- /* Kind of lame.Each menu can only be a submenu, and each menu can only
- have one submenu open */
- ObMenu *parent;
- ObMenu *open_submenu;
- GList *over;
-
- /* behaviour callbacks
- TODO: Document and split code that HAS to be in the overridden callback */
- /* place a menu on screen */
- menu_controller_show show;
- /* Hide the menu */
- menu_controller_hide hide;
- /* render a menu */
- menu_controller_update update;
- /* Event for a mouse enter/exit on an entry
- TODO: May have to split from simple render updating?
- */
- menu_controller_mouseover mouseover;
- /* Entry is clicked/hit enter on */
- menu_controller_selected selected;
-
-
- /* render stuff */
- struct _ObClient *client;
- Window frame;
- Window title;
- RrAppearance *a_title;
- gint title_min_w, title_h;
- Window items;
- RrAppearance *a_items;
- gint bullet_w;
- gint item_h;
- Point location;
- Size size;
- guint xin_area; /* index of the xinerama head/area */
-
- /* Name of plugin for menu */
- char *plugin;
- /* plugin's data */
- void *plugin_data;
+ /* plugin data */
+ gpointer data;
+
+ ObMenuUpdateFunc update_func;
+ ObMenuExecuteFunc execute_func;
+ ObMenuDestroyFunc destroy_func;
+
+ /* Pipe-menu parent, we get destroyed when it is destroyed */
+ ObMenu *pipe_creator;