From 07fe0980bec54cb787579a6b2633309d20fc083b Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Fri, 2 Mar 2007 22:11:46 +0000 Subject: declare variables at the beginning of blocks, because it is nice to do so. and polite? --- openbox/menuframe.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'openbox') diff --git a/openbox/menuframe.c b/openbox/menuframe.c index a3aee8be..e9fc32da 100644 --- a/openbox/menuframe.c +++ b/openbox/menuframe.c @@ -676,13 +676,14 @@ void menu_frame_hide(ObMenuFrame *self) void menu_frame_hide_all() { + GList *it; + if (config_submenu_show_delay) { /* remove any submenu open requests */ ob_main_loop_timeout_remove(ob_main_loop, menu_entry_frame_submenu_timeout); } - GList *it = g_list_last(menu_frame_visible); - if (it) + if ((it = g_list_last(menu_frame_visible))) menu_frame_hide(it->data); } -- cgit v1.2.3