summaryrefslogtreecommitdiff
path: root/gtk/gtkscale.c
diff options
context:
space:
mode:
authorTimm Bäder <mail@baedert.org>2016-03-16 10:20:17 +0100
committerTimm Bäder <mail@baedert.org>2016-03-16 10:20:17 +0100
commit985121813e2af706837e2e4d14019dec07762975 (patch)
tree471dc132e1fd906d89069e6d7925d29c18b9532b /gtk/gtkscale.c
parent6f3a3ea7f3445b0e9402d4e294778d86a4b94c8e (diff)
downloadgtk+-985121813e2af706837e2e4d14019dec07762975.tar.gz
scale: Fix value height calculation
if (orientation) doesn't make a lot of sense but C doesn't complain and instead evaluates orientation to TRUE for GTK_ORIENTATION_VERTICAL (since that's 1), thus inverting the value sizes.
Diffstat (limited to 'gtk/gtkscale.c')
-rw-r--r--gtk/gtkscale.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gtk/gtkscale.c b/gtk/gtkscale.c
index 9fe1bafcf2..ec5804d44f 100644
--- a/gtk/gtkscale.c
+++ b/gtk/gtkscale.c
@@ -1212,7 +1212,7 @@ gtk_scale_measure_value (GtkCssGadget *gadget,
g_object_unref (layout);
}
- if (orientation)
+ if (orientation == GTK_ORIENTATION_HORIZONTAL)
*minimum = *natural = width;
else
*minimum = *natural = height;