mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 20:59:16 +00:00
WindowServer: Add support for default MenuItem
This allows marking a MenuItem as a default action, e.g. in a context menu for an action that reflects what e.g. a double click would perform. Also enhance the window menu to mark the close action as the default, and when double clicked perform that action. Fixes #1289
This commit is contained in:
parent
684b04e02a
commit
fc4e01a3c9
Notes:
sideshowbarker
2024-07-19 04:58:08 +09:00
Author: https://github.com/tomuta
Commit: fc4e01a3c9
Pull-request: https://github.com/SerenityOS/serenity/pull/2736
Reviewed-by: https://github.com/awesomekling
10 changed files with 194 additions and 32 deletions
|
@ -648,7 +648,7 @@ void ClientConnection::handle(const Messages::WindowServer::WM_PopupWindowMenu&
|
|||
return;
|
||||
}
|
||||
auto& window = *(*it).value;
|
||||
window.popup_window_menu(message.screen_position());
|
||||
window.popup_window_menu(message.screen_position(), WindowMenuDefaultAction::BasedOnWindowState);
|
||||
}
|
||||
|
||||
void ClientConnection::handle(const Messages::WindowServer::WM_StartWindowResize& request)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue