mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 05:47:34 +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
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