diff options
author | Michael Natterer <mitch@imendio.com> | 2008-08-11 21:07:36 +0000 |
---|---|---|
committer | Michael Natterer <mitch@src.gnome.org> | 2008-08-11 21:07:36 +0000 |
commit | 74bc87842f0c8c6874ddcc547d86644583e6a2cd (patch) | |
tree | e0acc1896ace436647c9ad5b7f8960db340f7867 /gtk/gtkadjustment.c | |
parent | 6f789132c529933f76b84b9de1d137bda6dd90f1 (diff) | |
download | gtk+-74bc87842f0c8c6874ddcc547d86644583e6a2cd.tar.gz |
Bug 546754 – 2.13.6 update create rendering issue in the evolution
2008-08-11 Michael Natterer <mitch@imendio.com>
Bug 546754 – 2.13.6 update create rendering issue in the evolution
composer
* gtk/gtkadjustment.c: instead of CLAMP(), use
value = MIN (value, upper - page_size);
value = MAX (value, lower);
so we don't end up below lower if upper - page_size is smaller
than lower.
svn path=/trunk/; revision=21080
Diffstat (limited to 'gtk/gtkadjustment.c')
-rw-r--r-- | gtk/gtkadjustment.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/gtk/gtkadjustment.c b/gtk/gtkadjustment.c index 16e76ede8e..dd1b3f609d 100644 --- a/gtk/gtkadjustment.c +++ b/gtk/gtkadjustment.c @@ -359,7 +359,11 @@ gtk_adjustment_set_value (GtkAdjustment *adjustment, { g_return_if_fail (GTK_IS_ADJUSTMENT (adjustment)); - value = CLAMP (value, adjustment->lower, adjustment->upper - adjustment->page_size); + /* don't use CLAMP() so we don't end up below lower if upper - page_size + * is smaller than lower + */ + value = MIN (value, adjustment->upper - adjustment->page_size); + value = MAX (value, adjustment->lower); if (value != adjustment->value) { @@ -628,7 +632,11 @@ gtk_adjustment_configure (GtkAdjustment *adjustment, "page-size", page_size, NULL); - value = CLAMP (value, lower, upper - page_size); + /* don't use CLAMP() so we don't end up below lower if upper - page_size + * is smaller than lower + */ + value = MIN (value, upper - page_size); + value = MAX (value, lower); if (value != adjustment->value) { |