* 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
This commit is contained in:
Axel Dörfler 2009-11-26 11:29:26 +00:00
parent 1467a878b1
commit 0913b742ca

View File

@ -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);
}