- /* GList *tail; */
-
- /* ? */
- gboolean shown;
- gboolean invalid;
-
- struct Menu *parent;
-
- /* waste o' pointers */
- void (*show)( /* some bummu */);
- void (*hide)( /* some bummu */);
- void (*update)( /* some bummu */);
- void (*mouseover)( /* some bummu */);
- void (*selected)( /* some bummu */);
-
-
- /* render stuff */
- Client *client;
- Window frame;
- Window title;
- Appearance *a_title;
- int title_min_w, title_h;
- Window items;
- Appearance *a_items;
- int bullet_w;
- int item_h;
- int width;
-} Menu;
-
-typedef enum MenuEntryRenderType {
- MenuEntryRenderType_None = 0,
- MenuEntryRenderType_Submenu = 1 << 0,
- MenuEntryRenderType_Boolean = 1 << 1,
- MenuEntryRenderType_Separator = 1 << 2,
-
- MenuEntryRenderType_Other = 1 << 7
-} MenuEntryRenderType;
-
-typedef struct {
- char *label;
- Menu *parent;
-
- Action *action;
-
- MenuEntryRenderType render_type;
- gboolean hilite;
+
+ /* 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;
+};
+
+typedef enum
+{
+ OB_MENU_ENTRY_TYPE_NORMAL,
+ OB_MENU_ENTRY_TYPE_SUBMENU,
+ OB_MENU_ENTRY_TYPE_SEPARATOR
+} ObMenuEntryType;
+
+struct _ObNormalMenuEntry {
+ gchar *label;
+
+ /* state */