LibGUI: Add focus hooks to TextEditor

This commit is contained in:
AnotherTest 2020-07-04 22:37:55 +04:30 committed by Andreas Kling
commit c35493c156
Notes: sideshowbarker 2024-07-19 04:25:31 +09:00
2 changed files with 6 additions and 0 deletions

View file

@ -1152,11 +1152,15 @@ void TextEditor::focusin_event(Core::Event&)
m_cursor_state = true;
update_cursor();
start_timer(500);
if (on_focusin)
on_focusin();
}
void TextEditor::focusout_event(Core::Event&)
{
stop_timer();
if (on_focusout)
on_focusout();
}
void TextEditor::timer_event(Core::TimerEvent&)