mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-03-02 19:44:27 +00:00
Add a slight hover highlight to GButton and WSButton. :^)
This commit is contained in:
@@ -239,7 +239,7 @@ void WSWindowFrame::on_mouse_event(const WSMouseEvent& event)
|
||||
|
||||
for (auto& button : m_buttons) {
|
||||
if (button->relative_rect().contains(event.position()))
|
||||
return button->on_mouse_event(event);
|
||||
return button->on_mouse_event(event.translated(-button->relative_rect().location()));
|
||||
}
|
||||
if (event.type() == WSMessage::MouseDown && event.button() == MouseButton::Left)
|
||||
wm.start_window_drag(m_window, event.translated(rect().location()));
|
||||
|
||||
Reference in New Issue
Block a user