7124551: [macosx] Once added, Menu shortcut cannot be removed
authorserb
Thu, 29 Mar 2012 17:31:48 +0400
changeset 12283 253d9a09f674
parent 12282 b057800f17c2
child 12284 3f2477ebb708
7124551: [macosx] Once added, Menu shortcut cannot be removed Reviewed-by: art, anthony
jdk/src/macosx/native/sun/awt/CMenuItem.m
--- a/jdk/src/macosx/native/sun/awt/CMenuItem.m	Tue Mar 27 15:53:29 2012 +0400
+++ b/jdk/src/macosx/native/sun/awt/CMenuItem.m	Thu Mar 29 17:31:48 2012 +0400
@@ -125,11 +125,8 @@
 
     [JNFRunLoop performOnMainThreadWaiting:YES withBlock:^(){
         AWT_ASSERT_APPKIT_THREAD;
-
-        if (![theKeyEquivalent isEqualToString:@""]) {
-            [fMenuItem setKeyEquivalent:theKeyEquivalent];
-            [fMenuItem setKeyEquivalentModifierMask:modifierMask];
-        }
+        [fMenuItem setKeyEquivalent:theKeyEquivalent];
+        [fMenuItem setKeyEquivalentModifierMask:modifierMask];
         [fMenuItem setTitle:theLabel];
     }];
 }