(libinterface) Better-looking and functioning MenuButton

This commit is contained in:
Jaidyn Ann 2021-08-02 12:12:54 -05:00
parent 8cca8a324e
commit 930c500988

View File

@ -10,9 +10,10 @@
MenuButton::MenuButton(const char* name, const char* label, BMessage* message)
:
BButton(name, BString(label).Append(""), message),
BButton(name, label, message),
fMenu(NULL)
{
SetBehavior(B_POP_UP_BEHAVIOR);
}
@ -21,7 +22,7 @@ MenuButton::MouseDown(BPoint where)
{
BButton::MouseDown(where);
if (fMenu != NULL)
fMenu->Go(ConvertToScreen(where), true, true, true);
fMenu->Go(ConvertToScreen(Bounds().LeftBottom()), true, true, true);
}