r1149 - trunk/src/target/OM-2007/openmoko-libs/libmokoui

thomas at sita.openmoko.org thomas at sita.openmoko.org
Tue Feb 27 15:18:37 CET 2007


Author: thomas
Date: 2007-02-27 15:18:35 +0100 (Tue, 27 Feb 2007)
New Revision: 1149

Modified:
   trunk/src/target/OM-2007/openmoko-libs/libmokoui/moko-alignment.c
Log:
* Prevent MokoAlignment from attempting to allocate negative width or height to
  child widgets


Modified: trunk/src/target/OM-2007/openmoko-libs/libmokoui/moko-alignment.c
===================================================================
--- trunk/src/target/OM-2007/openmoko-libs/libmokoui/moko-alignment.c	2007-02-27 13:24:30 UTC (rev 1148)
+++ trunk/src/target/OM-2007/openmoko-libs/libmokoui/moko-alignment.c	2007-02-27 14:18:35 UTC (rev 1149)
@@ -201,6 +201,8 @@
 
             child_allocation.y = alignment->yalign * (height - child_allocation.height) + border_width + p_top;
         }
+	child_allocation.width = MAX (child_allocation.width, 0);
+	child_allocation.height = MAX (child_allocation.height, 0);
         gtk_widget_size_allocate (bin->child, &child_allocation);
     }
 }





More information about the commitlog mailing list