Fix slight issues when clicking on menu section buttons and missing isMouseInside in MouseEnter action for buttons
This commit is contained in:
parent
f1953603c0
commit
f41ab864ef
@ -242,6 +242,10 @@ public:
|
||||
{
|
||||
v->c->SetActiveMenu(menu);
|
||||
}
|
||||
void ActionCallback(ui::Button * sender)
|
||||
{
|
||||
MouseEnterCallback(sender);
|
||||
}
|
||||
};
|
||||
|
||||
class GameView::ToolAction: public ui::ButtonAction
|
||||
|
@ -136,12 +136,14 @@ void Button::OnMouseClick(int x, int y, unsigned int button)
|
||||
|
||||
void Button::OnMouseEnter(int x, int y)
|
||||
{
|
||||
isMouseInside = true;
|
||||
if(!Enabled)
|
||||
return;
|
||||
if(actionCallback)
|
||||
actionCallback->MouseEnterCallback(this);
|
||||
}
|
||||
|
||||
|
||||
void Button::OnMouseLeave(int x, int y)
|
||||
{
|
||||
isMouseInside = false;
|
||||
|
Loading…
Reference in New Issue
Block a user