mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-04 08:36:12 +00:00
LibGUI: Refine AbstractButton pressing behaviour
Previously the code couldn't handle leaving the AbstractButton through tab, while having it pressed through space or enter.
This commit is contained in:
parent
acd44bdcad
commit
34844dd547
Notes:
sideshowbarker
2024-07-18 03:24:32 +09:00
Author: https://github.com/frhun
Commit: 34844dd547
Pull-request: https://github.com/SerenityOS/serenity/pull/10209
2 changed files with 22 additions and 5 deletions
|
@ -50,6 +50,7 @@ protected:
|
|||
virtual void keyup_event(KeyEvent&) override;
|
||||
virtual void enter_event(Core::Event&) override;
|
||||
virtual void leave_event(Core::Event&) override;
|
||||
virtual void focusout_event(GUI::FocusEvent&) override;
|
||||
virtual void change_event(Event&) override;
|
||||
|
||||
void paint_text(Painter&, const Gfx::IntRect&, const Gfx::Font&, Gfx::TextAlignment, Gfx::TextWrapping = Gfx::TextWrapping::DontWrap);
|
||||
|
@ -60,6 +61,7 @@ private:
|
|||
bool m_checkable { false };
|
||||
bool m_hovered { false };
|
||||
bool m_being_pressed { false };
|
||||
bool m_being_keyboard_pressed { false };
|
||||
bool m_exclusive { false };
|
||||
|
||||
int m_auto_repeat_interval { 0 };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue