[gimp] Looking at widget->requisition in size_allocate() is useless
- From: Michael Natterer <mitch src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gimp] Looking at widget->requisition in size_allocate() is useless
- Date: Sat, 1 Aug 2009 17:03:13 +0000 (UTC)
commit 656e30cd3a6b1ab2380ea212d2c9b47b2c44d043
Author: Michael Natterer <mitch gimp org>
Date: Sat Aug 1 18:59:58 2009 +0200
Looking at widget->requisition in size_allocate() is useless
Use the passed GtkAllocation for calculating things, not
widget->requisition.
libgimpwidgets/gimpcolorscale.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/libgimpwidgets/gimpcolorscale.c b/libgimpwidgets/gimpcolorscale.c
index 5d8f9f6..005bde3 100644
--- a/libgimpwidgets/gimpcolorscale.c
+++ b/libgimpwidgets/gimpcolorscale.c
@@ -135,8 +135,8 @@ gimp_color_scale_size_allocate (GtkWidget *widget,
focus += focus_padding;
}
- range->min_slider_size = (MIN (widget->requisition.width,
- widget->requisition.height) - 2 * focus) / 2;
+ range->min_slider_size = (MIN (allocation->width,
+ allocation->height) - 2 * focus) / 2;
if (GTK_WIDGET_CLASS (parent_class)->size_allocate)
GTK_WIDGET_CLASS (parent_class)->size_allocate (widget, allocation);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]