summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSilenio Quarti <silenio_quarti@ca.ibm.com>2011-08-23 15:27:55 -0400
committerSilenio Quarti <silenio_quarti@ca.ibm.com>2011-08-23 15:27:55 -0400
commit35d457460fd1a9087e8ef21709ae071073770ebb (patch)
tree7292706788a8560d454d4a39c41f8171a184670f
parent0299941c68a463c97176c9da97b333292c2da0fb (diff)
downloadeclipse.platform.swt-35d457460fd1a9087e8ef21709ae071073770ebb.tar.gz
eclipse.platform.swt-35d457460fd1a9087e8ef21709ae071073770ebb.tar.xz
eclipse.platform.swt-35d457460fd1a9087e8ef21709ae071073770ebb.zip
Bug 353503 - [10.7][hovering][navigation] wrong size of pop-up dialog
for multi-hyperlink (previous was wrong when SWT style does not add scroll bars)
-rwxr-xr-xbundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java
index 204adc5a71..770be6ba9d 100755
--- a/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/cocoa/org/eclipse/swt/widgets/Scrollable.java
@@ -111,7 +111,10 @@ public Rectangle computeTrim (int x, int y, int width, int height) {
// Always include the scroll bar in the trim even when the scroll style is overlay
OS.objc_msgSend_stret(size, OS.class_NSScrollView,
OS.sel_frameSizeForContentSize_horizontalScrollerClass_verticalScrollerClass_borderType_controlSize_scrollerStyle_,
- size, OS.class_NSScroller, OS.class_NSScroller, border, OS.NSRegularControlSize, OS.NSScrollerStyleLegacy);
+ size,
+ (style & SWT.H_SCROLL) != 0 ? OS.class_NSScroller : 0,
+ (style & SWT.V_SCROLL) != 0 ? OS.class_NSScroller : 0,
+ border, OS.NSRegularControlSize, OS.NSScrollerStyleLegacy);
} else {
size = NSScrollView.frameSizeForContentSize(size, (style & SWT.H_SCROLL) != 0, (style & SWT.V_SCROLL) != 0, border);
}