[gitg] progress bin: handle border on allocation



commit 42b61b4f2c67a93484300020f12dc3f1bdcea400
Author: Ignacio Casal Quinteiro <icq gnome org>
Date:   Thu Mar 28 10:58:38 2013 +0100

    progress bin: handle border on allocation

 libgitg-gtk/gitg-gtk-progress-bin.vala |    9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/libgitg-gtk/gitg-gtk-progress-bin.vala b/libgitg-gtk/gitg-gtk-progress-bin.vala
index e50aa6a..6f853f1 100644
--- a/libgitg-gtk/gitg-gtk-progress-bin.vala
+++ b/libgitg-gtk/gitg-gtk-progress-bin.vala
@@ -80,10 +80,11 @@ namespace GitgGtk
                        if (child != null && child.get_visible())
                        {
                                Gtk.Allocation child_allocation = {};
-                               child_allocation.x = 0;
-                               child_allocation.y = 0;
-                               child_allocation.width = allocation.width;
-                               child_allocation.height = allocation.height;
+                               int border_width = (int)get_border_width();
+                               child_allocation.x = border_width;
+                               child_allocation.y = border_width;
+                               child_allocation.width = allocation.width - 2 * border_width;
+                               child_allocation.height = allocation.height - 2 * border_width;
 
                                child.size_allocate(child_allocation);
                        }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]