From d2e7feaa855352986ff78cc9b2017bcebb78ea6c Mon Sep 17 00:00:00 2001 From: Mathias Gumz Date: Fri, 25 Feb 2011 18:39:48 +0100 Subject: bugfix: submenus didn't hide if a delay was set use the FbTk::Timer API correctly, bug(s) introduced by 1f0adef4daa2da5b08ed7f41e7a0ce1e3f71e46f e68511794130388ab9668fdef0dcf48dbbf002fd --- src/AttentionNoticeHandler.cc | 2 +- src/FbTk/Menu.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/AttentionNoticeHandler.cc b/src/AttentionNoticeHandler.cc index 9425bb2..88dd72a 100644 --- a/src/AttentionNoticeHandler.cc +++ b/src/AttentionNoticeHandler.cc @@ -82,7 +82,7 @@ void AttentionNoticeHandler::addAttention(Focusable &client) { RefCount > cmd(new ToggleFrameFocusCmd(client)); Timer *timer = new Timer(); timer->setCommand(cmd); - timer->setTimeout(0, **timeout_res * 1000); + timer->setTimeout(**timeout_res); timer->fireOnce(false); // will repeat until window has focus timer->start(); diff --git a/src/FbTk/Menu.cc b/src/FbTk/Menu.cc index 6f997a5..a3b7793 100644 --- a/src/FbTk/Menu.cc +++ b/src/FbTk/Menu.cc @@ -1002,7 +1002,7 @@ void Menu::motionNotifyEvent(XMotionEvent &me) { } if (itmp->submenu()) { // start submenu open delay - m_submenu_timer.setTimeout(0, theme()->getDelay() * 1000); + m_submenu_timer.setTimeout(theme()->getDelay()); m_submenu_timer.start(); } else if (isItemSelectable(w)){ // else normal menu item @@ -1221,7 +1221,7 @@ void Menu::closeMenu() { } void Menu::startHide() { - m_hide_timer.setTimeout(theme()->getDelay() * 1000); + m_hide_timer.setTimeout(theme()->getDelay()); m_hide_timer.start(); } -- cgit v0.11.2