jdk/src/macosx/native/sun/awt/AWTWindow.m
changeset 17904 0be4c7d2e53b
parent 17684 fc7f8dbe87b4
child 18129 614a4d36d8c7
equal deleted inserted replaced
17903:643f1ca93dd6 17904:0be4c7d2e53b
   537 AWT_ASSERT_APPKIT_THREAD;
   537 AWT_ASSERT_APPKIT_THREAD;
   538     [AWTToolkit eventCountPlusPlus];
   538     [AWTToolkit eventCountPlusPlus];
   539     AWTWindow *opposite = [AWTWindow lastKeyWindow];
   539     AWTWindow *opposite = [AWTWindow lastKeyWindow];
   540     if (!IS(self.styleBits, IS_DIALOG)) {
   540     if (!IS(self.styleBits, IS_DIALOG)) {
   541         [CMenuBar activate:self.javaMenuBar modallyDisabled:NO];
   541         [CMenuBar activate:self.javaMenuBar modallyDisabled:NO];
   542     } else if (IS(self.styleBits, IS_MODAL)) {
   542     } else if ((opposite != NULL) && IS(self.styleBits, IS_MODAL)) {
   543         [CMenuBar activate:opposite->javaMenuBar modallyDisabled:YES];        
   543         [CMenuBar activate:opposite->javaMenuBar modallyDisabled:YES];        
   544     }
   544     }
   545     [AWTWindow setLastKeyWindow:nil];
   545     [AWTWindow setLastKeyWindow:nil];
   546 
   546 
   547     [self _deliverWindowFocusEvent:YES oppositeWindow: opposite];
   547     [self _deliverWindowFocusEvent:YES oppositeWindow: opposite];