Author: axeld Date: 2009-11-26 12:29:26 +0100 (Thu, 26 Nov 2009) New Revision: 34274 Changeset: http://dev.haiku-os.org/changeset/34274/haiku Ticket: http://dev.haiku-os.org/ticket/5037 Modified: haiku/trunk/src/apps/deskbar/ExpandoMenuBar.cpp Log: * Moved the double click check after the expander bounds check, fixing bug #5037. Modified: haiku/trunk/src/apps/deskbar/ExpandoMenuBar.cpp =================================================================== --- haiku/trunk/src/apps/deskbar/ExpandoMenuBar.cpp 2009-11-26 11:11:17 UTC (rev 34273) +++ haiku/trunk/src/apps/deskbar/ExpandoMenuBar.cpp 2009-11-26 11:29:26 UTC (rev 34274) @@ -326,18 +326,6 @@ } } - // 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 @@ } } + // 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); }