[gtk+/gtk-3-0] frame: Make sure the size we compute doesn't get unsigned-promoted
- From: Benjamin Otte <otte src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-3-0] frame: Make sure the size we compute doesn't get unsigned-promoted
- Date: Sat, 2 Apr 2011 01:59:00 +0000 (UTC)
commit 6647a735631ed10318a2b422b31340b90ef1e5df
Author: Benjamin Otte <otte redhat com>
Date: Sat Apr 2 03:54:38 2011 +0200
frame: Make sure the size we compute doesn't get unsigned-promoted
gtk/gtkframe.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gtk/gtkframe.c b/gtk/gtkframe.c
index 62e0dc1..059aea1 100644
--- a/gtk/gtkframe.c
+++ b/gtk/gtkframe.c
@@ -757,7 +757,7 @@ gtk_frame_real_compute_child_allocation (GtkFrame *frame,
GtkStateFlags state;
GtkBorder padding;
gint top_margin;
- guint border_width;
+ gint border_width;
context = gtk_widget_get_style_context (widget);
state = gtk_widget_get_state_flags (widget);
@@ -792,9 +792,9 @@ gtk_frame_real_compute_child_allocation (GtkFrame *frame,
child_allocation->x = border_width + padding.left;
child_allocation->y = border_width + top_margin;
- child_allocation->width = MAX (1, (gint) allocation.width - (border_width * 2) -
+ child_allocation->width = MAX (1, allocation.width - (border_width * 2) -
padding.left - padding.right);
- child_allocation->height = MAX (1, ((gint) allocation.height - child_allocation->y -
+ child_allocation->height = MAX (1, (allocation.height - child_allocation->y -
border_width - padding.bottom));
child_allocation->x += allocation.x;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]