1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 04:17:35 +00:00

WindowServer: Support Alt shortcuts inside menus as well

Menu items can now also have Alt shortcut, and they work the same way
top-level menu Alt shortcuts do. This replaces the previous "type to
search" mechanism we had in menus.
This commit is contained in:
Andreas Kling 2021-04-09 13:48:26 +02:00
parent 2b9bc605d2
commit 0fc2651303
4 changed files with 32 additions and 31 deletions

View file

@ -42,10 +42,10 @@ namespace WindowServer {
class ClientConnection;
class MenuBar;
class Event;
class Menu final : public Core::Object {
C_OBJECT(Menu)
C_OBJECT(Menu);
public:
Menu(ClientConnection*, int menu_id, String name);
virtual ~Menu() override;
@ -160,4 +160,6 @@ private:
int m_max_scroll_offset { 0 };
};
u32 find_ampersand_shortcut_character(const StringView&);
}