mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-22 12:35:14 +00:00
LibGUI: Properly remove auto-destroyed child windows from reified_windows.
I just spotted this while I saw you writing this code :-)
This commit is contained in:
parent
a63e8c4a03
commit
e347d6bdb8
Notes:
sideshowbarker
2024-07-19 07:02:27 +09:00
Author: https://github.com/emilio 🔰 Commit: https://github.com/SerenityOS/serenity/commit/e347d6bdb85 Pull-request: https://github.com/SerenityOS/serenity/pull/2069
1 changed files with 1 additions and 1 deletions
|
@ -128,6 +128,7 @@ Window* Window::find_parent_window()
|
|||
|
||||
void Window::server_did_destroy()
|
||||
{
|
||||
reified_windows->remove(m_window_id);
|
||||
m_window_id = 0;
|
||||
m_visible = false;
|
||||
m_pending_paint_event_rects.clear();
|
||||
|
@ -140,7 +141,6 @@ void Window::hide()
|
|||
{
|
||||
if (!is_visible())
|
||||
return;
|
||||
reified_windows->remove(m_window_id);
|
||||
auto response = WindowServerConnection::the().send_sync<Messages::WindowServer::DestroyWindow>(m_window_id);
|
||||
server_did_destroy();
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue