Style fixes to ExpandoMenuBar

This commit is contained in:
John Scipione
2013-05-28 18:07:23 -04:00
parent 83fd8a6199
commit d0f798c8d2
2 changed files with 12 additions and 11 deletions
+5 -6
View File
@@ -396,6 +396,7 @@ TExpandoMenuBar::MouseMoved(BPoint where, uint32 code, const BMessage* message)
SetToolTip(windowMenuItem->FullTitle());
} else
SetToolTip((const char*)NULL);
break;
}
@@ -406,12 +407,10 @@ TExpandoMenuBar::MouseMoved(BPoint where, uint32 code, const BMessage* message)
break;
}
// new item, set the tooltip to the item name
SetToolTip(item->Name());
// save the current menuitem for the next MouseMoved() call
// new item, set the tooltip to the item name
fLastMousedOverItem = menuItem;
// save the current menuitem for the next MouseMoved() call
break;
}
@@ -422,8 +421,8 @@ TExpandoMenuBar::MouseMoved(BPoint where, uint32 code, const BMessage* message)
{
TTeamMenuItem* lastItem
= dynamic_cast<TTeamMenuItem*>(fLastClickedItem);
if (fVertical && fShowTeamExpander && fClickedExpander
&& lastItem != NULL) {
if (lastItem != NULL && fVertical && fShowTeamExpander
&& fClickedExpander) {
// Started expander animation, then exited view,
// since we can't track outside mouse movements
// redraw the original expander arrow
+7 -5
View File
@@ -45,11 +45,6 @@ All rights reserved.
#include <Locker.h>
class BBitmap;
class TBarView;
class TBarMenuTitle;
class TTeamMenuItem;
//#define DOUBLECLICKBRINGSTOFRONT
enum drag_and_drop_selection {
@@ -59,6 +54,13 @@ enum drag_and_drop_selection {
kAnyMenuSelection
};
class BBitmap;
class TBarView;
class TBarMenuTitle;
class TTeamMenuItem;
class TExpandoMenuBar : public BMenuBar {
public:
TExpandoMenuBar(BRect frame, const char* name,