1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 10:47:35 +00:00

WindowServer: Move titlebar button mouse event handling to a function

The button widgets internally rendered by WindowServer are only used
in titlebars, and require a bit of mouse event handling. Instead of
mixing it with the window-oriented mouse event handling, get the
button event stuff out of the way first.
This commit is contained in:
Andreas Kling 2021-06-18 14:51:27 +02:00
parent 5d73e16edf
commit 09dacf4cd1
2 changed files with 17 additions and 6 deletions

View file

@ -240,6 +240,7 @@ private:
bool process_ongoing_window_move(MouseEvent&, Window*& hovered_window);
bool process_ongoing_drag(MouseEvent&, Window*& hovered_window);
bool process_ongoing_active_input_mouse_event(MouseEvent&, Window*& hovered_window);
bool process_mouse_event_for_titlebar_buttons(MouseEvent&);
template<typename Callback>
void for_each_window_manager(Callback);