Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnatoly Spektor2013-07-12 18:22:57 +0000
committerArun Thondapu2013-07-18 09:53:04 +0000
commit84ada67db50238f5e2d9101d22b8080e28b074d2 (patch)
treea7963ed646999656a0486a8f01b95332b3ee74da
parentf44fbcfe05943df863742d52c93eee02ea76cf56 (diff)
downloadeclipse.platform.swt-84ada67db50238f5e2d9101d22b8080e28b074d2.tar.gz
eclipse.platform.swt-84ada67db50238f5e2d9101d22b8080e28b074d2.tar.xz
eclipse.platform.swt-84ada67db50238f5e2d9101d22b8080e28b074d2.zip
Bug 412880 - Dropping Version less than 2.10 in Widget and Tooltip
Signed-off-by: Anatoly Spektor <aspektor@redhat.com>
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolTip.java19
-rw-r--r--bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Widget.java5
2 files changed, 4 insertions, 20 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolTip.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolTip.java
index 8784c9b5f6..7ae3ae929b 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolTip.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolTip.java
@@ -344,21 +344,10 @@ Point getLocation () {
int y = this.y;
if (item != null) {
long /*int*/ itemHandle = item.handle;
- if (OS.GTK_VERSION >= OS.VERSION (2, 10, 0)) {
- GdkRectangle area = new GdkRectangle ();
- OS.gtk_status_icon_get_geometry (itemHandle, 0, area, 0);
- x = area.x + area.width / 2;
- y = area.y + area.height / 2;
- } else {
- OS.gtk_widget_realize (itemHandle);
- long /*int*/ window = gtk_widget_get_window (itemHandle);
- int [] px = new int [1], py = new int [1];
- OS.gdk_window_get_origin (window, px, py);
- GtkAllocation allocation = new GtkAllocation ();
- gtk_widget_get_allocation (itemHandle, allocation);
- x = px [0] + allocation.width / 2;
- y = py [0] + allocation.height / 2;
- }
+ GdkRectangle area = new GdkRectangle ();
+ OS.gtk_status_icon_get_geometry (itemHandle, 0, area, 0);
+ x = area.x + area.width / 2;
+ y = area.y + area.height / 2;
}
if (x == -1 || y == -1) {
int [] px = new int [1], py = new int [1];
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Widget.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Widget.java
index f9666a80ba..d8c48aaf2c 100644
--- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Widget.java
+++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Widget.java
@@ -332,11 +332,6 @@ void checkOrientation (Widget parent) {
}
}
style = checkBits (style, SWT.LEFT_TO_RIGHT, SWT.RIGHT_TO_LEFT, 0, 0, 0, 0);
- /* Versions of GTK prior to 2.8 do not render RTL text properly */
- if (OS.GTK_VERSION < OS.VERSION (2, 8, 0)) {
- style &= ~SWT.RIGHT_TO_LEFT;
- style |= SWT.LEFT_TO_RIGHT;
- }
}
/**

Back to the top