mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 03:57:44 +00:00
LibGUI+WindowServer: Add support for per-GWidget context menus.
You can now simply assign a GMenu as a GWidget's context menu and it will automagically pop up on right click. :^)
This commit is contained in:
parent
8feecf6c77
commit
c06a3bdeb4
12 changed files with 102 additions and 8 deletions
|
@ -192,6 +192,7 @@ struct WSAPI_ClientMessage {
|
|||
GetWallpaper,
|
||||
SetWindowOverrideCursor,
|
||||
WM_SetActiveWindow,
|
||||
PopupMenu,
|
||||
};
|
||||
Type type { Invalid };
|
||||
int window_id { -1 };
|
||||
|
@ -214,6 +215,7 @@ struct WSAPI_ClientMessage {
|
|||
char shortcut_text[32];
|
||||
int shortcut_text_length;
|
||||
bool enabled;
|
||||
WSAPI_Point position;
|
||||
} menu;
|
||||
struct {
|
||||
WSAPI_Rect rect;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue