From 03d42b5d8253ad2de94df20b12b9fb22ce51eb3d Mon Sep 17 00:00:00 2001 From: Scott Moynes Date: Sat, 10 May 2003 14:51:27 +0000 Subject: Timed menu that reads output from a process while the window is hidden --- openbox/menu.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'openbox/menu.c') diff --git a/openbox/menu.c b/openbox/menu.c index b271cf31..74c23482 100644 --- a/openbox/menu.c +++ b/openbox/menu.c @@ -90,11 +90,11 @@ void menu_startup() menu_add_entry(m, menu_entry_new_submenu("subz", s)); - /* t = (Menu *)plugin_create("timed_menu"); a = action_from_string("execute"); a->data.execute.path = g_strdup("xeyes"); - menu_add_entry(t, menu_entry_new("xeyes", a));*/ + menu_add_entry(t, menu_entry_new("xeyes", a)); + menu_add_entry(m, menu_entry_new_submenu("timed", t)); s = menu_new("empty", "chub", m); menu_add_entry(m, menu_entry_new_submenu("empty", s)); @@ -293,6 +293,17 @@ void menu_hide(Menu *self) { } } +void menu_clear(Menu *self) { + GList *it; + + for (it = self->entries; it; it = it->next) { + MenuEntry *entry = it->data; + menu_entry_free(entry); + } + self->entries = NULL; +} + + MenuEntry *menu_find_entry(Menu *menu, Window win) { GList *it; -- cgit v1.2.3