From 4663a9591e08b554f82366cdd8e9075b0a6fbe55 Mon Sep 17 00:00:00 2001 From: Mathias Gumz Date: Wed, 23 Sep 2009 22:21:13 +0200 Subject: bugfix: 'HideMenus' command did not work if the user 'opened' an empty submenu. 'openeing' such an empty submenu lead to an already hidden menu referenced by the 'shown' pointer --- ChangeLog | 5 +++++ src/FbTk/Menu.cc | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index bb758e8..7b875bf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,10 @@ (Format: Year/Month/Day) Changes for 1.1.2 + +*09/09/23: + * Bugfix: Empty submenus lead to misfunction of the 'HideMenus' command (Mathias) + FbTk/Menu.cc + *09/09/12: * Implemented visibility of titlebar buttons via the apps file (Mathias) Window.cc diff --git a/src/FbTk/Menu.cc b/src/FbTk/Menu.cc index 4489d0f..ded5dab 100644 --- a/src/FbTk/Menu.cc +++ b/src/FbTk/Menu.cc @@ -759,7 +759,7 @@ void Menu::drawSubmenu(unsigned int index) { if (! m_moving) clearItem(index); - if (! item->submenu()->isVisible()) { + if (! item->submenu()->isVisible() && item->submenu()->numberOfItems() > 0) { shown = item->submenu(); item->showSubmenu(); item->submenu()->raise(); -- cgit v0.11.2