fixed bug in CPMenu where action would be sent when the user clicked on a disabled menu item.

This commit is contained in:
Randall Luecke authored and Ross Boucher committed 2009-12-18 18:43:03 -05:00
1 parent 648fbe1b10
commit 1411410f4e
1 file changed
+1 -1
+1 -1
View File
@@ -648,7 +648,7 @@ var _CPMenuBarVisible = NO,
while ([highlightedItem submenu] && [highlightedItem action] === @selector(submenuAction:))
highlightedItem = [[highlightedItem submenu] highlightedItem];
if (highlightedItem)
if (highlightedItem && [highlightedItem isEnabled])
[CPApp sendAction:[highlightedItem action] to:[highlightedItem target] from:highlightedItem];
}