summaryrefslogtreecommitdiff
path: root/Servers/WindowServer/Menu.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Servers/WindowServer/Menu.cpp')
-rw-r--r--Servers/WindowServer/Menu.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/Servers/WindowServer/Menu.cpp b/Servers/WindowServer/Menu.cpp
index 669aaf30ce..cb38736e95 100644
--- a/Servers/WindowServer/Menu.cpp
+++ b/Servers/WindowServer/Menu.cpp
@@ -393,6 +393,8 @@ void Menu::event(Core::Event& event)
}
if (key == Key_Return) {
+ if (!hovered_item()->is_enabled())
+ return;
if (hovered_item()->is_submenu())
descend_into_submenu_at_hovered_item();
else
@@ -461,7 +463,7 @@ void Menu::event(Core::Event& event)
}
if (key == Key_Right) {
- if (hovered_item()->is_submenu())
+ if (hovered_item()->is_enabled() && hovered_item()->is_submenu())
descend_into_submenu_at_hovered_item();
return;
}