mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 07:17:35 +00:00
Redraw both incoming and outgoing widget when changing focus.
This commit is contained in:
parent
07873332e7
commit
b7d83e3265
3 changed files with 6 additions and 1 deletions
|
@ -128,10 +128,13 @@ void Window::setFocusedWidget(Widget* widget)
|
|||
m_focusedWidget = nullptr;
|
||||
else {
|
||||
m_focusedWidget = widget->makeWeakPtr();
|
||||
m_focusedWidget->update();
|
||||
EventLoop::main().postEvent(m_focusedWidget.ptr(), make<Event>(Event::FocusIn));
|
||||
}
|
||||
if (previously_focused_widget)
|
||||
if (previously_focused_widget) {
|
||||
previously_focused_widget->update();
|
||||
EventLoop::main().postEvent(previously_focused_widget, make<Event>(Event::FocusOut));
|
||||
}
|
||||
}
|
||||
|
||||
void Window::close()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue