diff options
author | Anatoly Spektor <aspektor@redhat.com> | 2012-08-03 15:05:43 -0400 |
---|---|---|
committer | Silenio Quarti <silenio_quarti@ca.ibm.com> | 2012-08-03 20:33:29 -0400 |
commit | 6a88076d643ac9b570062b746912ac639cf39eaf (patch) | |
tree | 9327e21210c6700b04b8b3140d94b508851a1157 /bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Button.java | |
parent | 88dc3a4dc3c68bb6669db018f4d6d63689ecddba (diff) | |
download | eclipse.platform.swt-6a88076d643ac9b570062b746912ac639cf39eaf.tar.gz eclipse.platform.swt-6a88076d643ac9b570062b746912ac639cf39eaf.tar.xz eclipse.platform.swt-6a88076d643ac9b570062b746912ac639cf39eaf.zip |
Bug 386594 - Use gtk_widget_get_visible instead of GTK_WIDGET_VISIBLE for newer GTK+
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Button.java')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Button.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Button.java b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Button.java index bc11b73d58..8a1d466bc9 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Button.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/Button.java @@ -214,7 +214,7 @@ public Point computeSize (int wHint, int hHint, boolean changed) { } } int imageWidth = 0, imageHeight = 0; - if (OS.GTK_WIDGET_VISIBLE (imageHandle)) { + if (gtk_widget_get_visible (imageHandle)) { GtkRequisition requisition = new GtkRequisition (); OS.gtk_widget_size_request (imageHandle, requisition); imageWidth = requisition.width; @@ -677,7 +677,7 @@ void _setAlignment (int alignment) { style &= ~(SWT.LEFT | SWT.RIGHT | SWT.CENTER); style |= alignment & (SWT.LEFT | SWT.RIGHT | SWT.CENTER); /* Alignment not honoured when image and text are visible */ - boolean bothVisible = OS.GTK_WIDGET_VISIBLE (labelHandle) && OS.GTK_WIDGET_VISIBLE (imageHandle); + boolean bothVisible = gtk_widget_get_visible (labelHandle) && gtk_widget_get_visible (imageHandle); if (bothVisible) { if ((style & (SWT.RADIO | SWT.CHECK)) != 0) alignment = SWT.LEFT; if ((style & (SWT.PUSH | SWT.TOGGLE)) != 0) alignment = SWT.CENTER; @@ -770,7 +770,7 @@ int setBounds (int x, int y, int width, int height, boolean move, boolean resize OS.pango_layout_get_size (labelLayout, w, h); OS.pango_layout_set_width (labelLayout, pangoWidth); int imageWidth = 0; - if (OS.GTK_WIDGET_VISIBLE (imageHandle)) { + if (gtk_widget_get_visible (imageHandle)) { GtkRequisition requisition = new GtkRequisition (); OS.gtk_widget_size_request (imageHandle, requisition); imageWidth = requisition.width; |