summaryrefslogtreecommitdiffstats
path: root/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java
diff options
context:
space:
mode:
authorSilenio Quarti <silenio_quarti@ca.ibm.com>2012-09-06 09:49:14 -0400
committerSilenio Quarti <silenio_quarti@ca.ibm.com>2012-09-06 09:49:14 -0400
commit904726b3be2bccd3138b183ec66e6878016a6ed0 (patch)
treece68e522dc6dbb38d184af1101006148f307c667 /bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java
parent572d213ab35a497c10eab2f88d0a1f11c36bb71c (diff)
downloadeclipse.platform.swt-904726b3be2bccd3138b183ec66e6878016a6ed0.tar.gz
eclipse.platform.swt-904726b3be2bccd3138b183ec66e6878016a6ed0.tar.xz
eclipse.platform.swt-904726b3be2bccd3138b183ec66e6878016a6ed0.zip
Bug 387338 - Cocoa: [New SWT style required]single click only bring a
window to the top but do not take effective for the click object
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java')
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java
index 6678d079cb..e2622c6878 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Composite.java
@@ -127,6 +127,13 @@ Control [] _getTabList () {
return tabList;
}
+boolean acceptsFirstMouse (int /*long*/ id, int /*long*/ sel, int /*long*/ theEvent) {
+ if ((state & CANVAS) != 0) {
+ return true;
+ }
+ return super.acceptsFirstMouse (id, sel, theEvent);
+}
+
boolean acceptsFirstResponder (int /*long*/ id, int /*long*/ sel) {
if ((state & CANVAS) != 0) {
if ((style & SWT.NO_FOCUS) == 0 && hooksKeys ()) {