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

LibGUI: Tweak GUI::Button::on_context_menu_event hook signature

Pass the ContextMenuEvent as a mutable reference, so that clients
want to accept/ignore the event.
This commit is contained in:
Andreas Kling 2021-05-15 22:55:57 +02:00
parent 5daf7bd2ef
commit 0ee7991dca

View file

@ -28,7 +28,7 @@ public:
Gfx::TextAlignment text_alignment() const { return m_text_alignment; }
Function<void(unsigned modifiers)> on_click;
Function<void(const ContextMenuEvent&)> on_context_menu_request;
Function<void(ContextMenuEvent&)> on_context_menu_request;
void set_button_style(Gfx::ButtonStyle style) { m_button_style = style; }
Gfx::ButtonStyle button_style() const { return m_button_style; }