From 486cb9d274cada4c313732fb1f41ca4e0cc984ca Mon Sep 17 00:00:00 2001 From: Silenio Quarti Date: Thu, 21 Jun 2012 14:41:08 -0400 Subject: Bug 381333 - MouseExit event is not received in shell with style SWT.ON_TOP --- .../Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java index cd0717f124..f897e09350 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Shell.java @@ -1987,7 +1987,16 @@ void setWindowVisible (boolean visible, boolean key) { sendEvent (SWT.Hide); } + if (isDisposed()) return; display.updateQuitMenu(); + + if (isDisposed()) return; + NSView[] hitView = new NSView[1]; + Control control = display.findControl (false, hitView); + if (control != null && (!control.isActive() || !control.isEnabled())) control = null; + Control trimControl = control; + if (trimControl != null && trimControl.isTrim (hitView[0])) trimControl = null; + display.checkEnterExit (trimControl, null, false); } void setZOrder () { -- cgit