mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 02:47:35 +00:00
WindowManager: Move more of the menu management logic to WSMenuManager
This patch moves a whole lot of the menu logic from WSWindowManager to its proper home in WSMenuManager. We also get rid of the "close_current_menu()" concept which was easily confused in the presence of submenus. All operations should now be aware of the menu stack instead. (The concept of a single, current menu made a lot more sense when there were no nested menus.)
This commit is contained in:
parent
77de51d251
commit
cbecad0a77
7 changed files with 126 additions and 96 deletions
|
@ -388,7 +388,7 @@ void WSClientConnection::handle_request(const WSAPIDestroyMenuRequest& request)
|
|||
return;
|
||||
}
|
||||
auto& menu = *(*it).value;
|
||||
WSWindowManager::the().close_menu(menu);
|
||||
menu.close();
|
||||
m_menus.remove(it);
|
||||
remove_child(menu);
|
||||
WSAPI_ServerMessage response;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue