From 0913b742cabbc59a52974cdc08b2b9551d85414f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Thu, 26 Nov 2009 11:29:26 +0000 Subject: [PATCH] * Moved the double click check after the expander bounds check, fixing bug #5037. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34274 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/apps/deskbar/ExpandoMenuBar.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/apps/deskbar/ExpandoMenuBar.cpp b/src/apps/deskbar/ExpandoMenuBar.cpp index 3a4263dd6f..6a34b080b2 100644 --- a/src/apps/deskbar/ExpandoMenuBar.cpp +++ b/src/apps/deskbar/ExpandoMenuBar.cpp @@ -326,18 +326,6 @@ TExpandoMenuBar::MouseDown(BPoint where) } } - // double-click on an item brings the team to front - int32 clicks; - if (message != NULL && message->FindInt32("clicks", &clicks) == B_OK - && clicks > 1) { - if (item == menuItem && item == fLastClickItem) { - // activate this team - be_roster->ActivateApp((team_id)item->Teams()->ItemAt(0)); - return; - } - } else - fLastClickItem = item; - // control click - show all/hide all shortcut int32 modifiers; if (message != NULL && message->FindInt32("modifiers", &modifiers) == B_OK @@ -369,6 +357,18 @@ TExpandoMenuBar::MouseDown(BPoint where) } } + // double-click on an item brings the team to front + int32 clicks; + if (message != NULL && message->FindInt32("clicks", &clicks) == B_OK + && clicks > 1) { + if (item == menuItem && item == fLastClickItem) { + // activate this team + be_roster->ActivateApp((team_id)item->Teams()->ItemAt(0)); + return; + } + } else + fLastClickItem = item; + BMenuBar::MouseDown(where); }