mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 13:37:44 +00:00
LibGUI: Don't crash when updating menu item that's not in the window server (#83)
Don't crash when updating menu item that's not in the window server. Menu Items begin with an invalid ID of -1, and only get a valid ID if the menu they are attached to is added to the window server. They don't send updates to the server unless they have a valid ID. Fixes #82
This commit is contained in:
parent
ebf645d72a
commit
9823354754
4 changed files with 7 additions and 2 deletions
|
@ -36,7 +36,7 @@ private:
|
|||
void update_window_server();
|
||||
|
||||
Type m_type { Invalid };
|
||||
unsigned m_menu_id { 0 };
|
||||
int m_menu_id { -1 };
|
||||
unsigned m_identifier { 0 };
|
||||
bool m_enabled { true };
|
||||
bool m_checkable { false };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue