diff options
Diffstat (limited to 'src/ui/control.cpp')
-rw-r--r-- | src/ui/control.cpp | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/src/ui/control.cpp b/src/ui/control.cpp index 04d89b5f..e3b7b967 100644 --- a/src/ui/control.cpp +++ b/src/ui/control.cpp @@ -16,11 +16,15 @@ using platform::native::IUiApplication; using platform::native::SystemCursorType; Control::Control() { - MouseEnterEvent()->Direct()->AddHandler( - [this](event::MouseEventArgs&) { this->is_mouse_over_ = true; }); - - MouseLeaveEvent()->Direct()->AddHandler( - [this](event::MouseEventArgs&) { this->is_mouse_over_ = false; }); + MouseEnterEvent()->Direct()->AddHandler([this](event::MouseEventArgs&) { + this->is_mouse_over_ = true; + this->OnMouseHoverChange(true); + }); + + MouseLeaveEvent()->Direct()->AddHandler([this](event::MouseEventArgs&) { + this->is_mouse_over_ = false; + this->OnMouseHoverChange(true); + }); } void Control::_SetParent(Control* parent) { |