1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 06:07:34 +00:00

WindowServer+LibGUI: Make menubar allocation asynchronous

Same as with menu allocation, move menubar ID management to the client
side, removing more IPC stalls during application startup.
This commit is contained in:
Andreas Kling 2021-05-17 13:31:14 +02:00
parent baab0a5bef
commit 7e799529b9
4 changed files with 9 additions and 7 deletions

View file

@ -81,12 +81,10 @@ void ClientConnection::notify_about_new_screen_rect(Gfx::IntRect const& rect)
async_screen_rect_changed(rect);
}
Messages::WindowServer::CreateMenubarResponse ClientConnection::create_menubar()
void ClientConnection::create_menubar(i32 menubar_id)
{
int menubar_id = m_next_menubar_id++;
auto menubar = Menubar::create(*this, menubar_id);
m_menubars.set(menubar_id, move(menubar));
return menubar_id;
}
void ClientConnection::destroy_menubar(i32 menubar_id)