From 81cc0749f8fe6e5a1f3474c07b26de2c49648526 Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Sun, 11 May 2003 19:50:30 +0000 Subject: Menus put themselves into the stacking list. Clicking on the menu (but not on an entry) will raise it. --- openbox/menu.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'openbox/menu.c') diff --git a/openbox/menu.c b/openbox/menu.c index 7af380db..611a53bc 100644 --- a/openbox/menu.c +++ b/openbox/menu.c @@ -38,6 +38,8 @@ void menu_destroy_hash_value(Menu *self) g_hash_table_remove(menu_map, &self->frame); g_hash_table_remove(menu_map, &self->items); + stacking_remove(self); + appearance_free(self->a_title); XDestroyWindow(ob_display, self->title); XDestroyWindow(ob_display, self->frame); @@ -197,6 +199,9 @@ Menu *menu_new_full(char *label, char *name, Menu *parent, g_hash_table_insert(menu_map, &self->title, self); g_hash_table_insert(menu_map, &self->items, self); g_hash_table_insert(menu_hash, g_strdup(name), self); + + stacking_add(self); + return self; } @@ -355,6 +360,7 @@ void menu_control_show(Menu *self, int x, int y, Client *client) { stacking_raise(MENU_AS_WINDOW(self)); */ XMapWindow(ob_display, self->frame); + stacking_raise(MENU_AS_WINDOW(self)); self->shown = TRUE; } else if (self->shown && self->open_submenu) { menu_hide(self->open_submenu); -- cgit v1.2.3