summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBogdan Gheorghe <gheorghe@ca.ibm.com>2013-05-16 11:38:32 -0400
committerBogdan Gheorghe <gheorghe@ca.ibm.com>2013-05-16 11:38:32 -0400
commitb402979b5de3a90d8705dbe2f45ac1f801226c5e (patch)
tree4f466b4603102e077ec29c8b9e613b9c0d7d963b
parent2acd4f33955e0302ee2ed62b6217b9bce1de8a6a (diff)
downloadeclipse.platform.swt-b402979b5de3a90d8705dbe2f45ac1f801226c5e.tar.gz
eclipse.platform.swt-b402979b5de3a90d8705dbe2f45ac1f801226c5e.tar.xz
eclipse.platform.swt-b402979b5de3a90d8705dbe2f45ac1f801226c5e.zip
Bug 358376 - Provide ability to handle reopen-events (user clicks dock icon for running application)
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java
index 230fc2b2aa..c8b8c7c72d 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Display.java
@@ -5274,7 +5274,9 @@ static long /*int*/ applicationProc(long /*int*/ id, long /*int*/ sel, long /*in
}
new NSApplication(arg0).replyToOpenOrPrint(OS.NSApplicationDelegateReplySuccess);
} else if (sel == OS.sel_applicationShouldHandleReopen_hasVisibleWindows_) {
- return 1;
+ final Event event = new Event();
+ display.sendEvent(SWT.Activate, event);
+ return event.doit ? 1 : 0;
}
return 0;
}