1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 11:58:12 +00:00

WindowServer: Don't re-render the window frame when not needed

Merely moving a window shouldn't require re-rendering the window
frame anymore now that we cache the rendered frame in bitmaps. This
reduces CPU usage significantly when moving windows.
This commit is contained in:
Tom 2021-02-10 11:54:58 -07:00 committed by Andreas Kling
parent 497d48a8de
commit f8d65e57ba
5 changed files with 22 additions and 23 deletions

View file

@ -466,7 +466,7 @@ OwnPtr<Messages::WindowServer::CreateWindowResponse> ClientConnection::handle(co
window->set_size_increment(message.size_increment());
window->set_base_size(message.base_size());
window->set_resize_aspect_ratio(message.resize_aspect_ratio());
window->invalidate();
window->invalidate(true, true);
if (window->type() == WindowType::MenuApplet)
AppletManager::the().add_applet(*window);
m_windows.set(window_id, move(window));