Added a new check of scrollbars layout in the allocation
authorAlejandro G. Castro <alex@igalia.com>
Tue, 11 Aug 2009 12:53:40 +0000 (14:53 +0200)
committerAlejandro G. Castro <alex@igalia.com>
Tue, 11 Aug 2009 12:53:40 +0000 (14:53 +0200)
* hildon/hildon-pannable-area.c
(hildon_pannable_area_size_allocate): Checked the scrollbars
before the first try when defining the layout, avoids two
allocations in some situations.

Fixes: NB#131794 (pannable area produces unnecessary allocations
causing performance problems)

ChangeLog
hildon/hildon-pannable-area.c

index 9f0b6e6..997c480 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,16 @@
 2009-08-11  Alejandro G. Castro  <alex@igalia.com>
 
        * hildon/hildon-pannable-area.c
+       (hildon_pannable_area_size_allocate): Checked the scrollbars
+       before the first try when defining the layout, avoids two
+       allocations in some situations.
+
+       Fixes: NB#131794 (pannable area produces unnecessary allocations
+       causing performance problems)
+
+2009-08-11  Alejandro G. Castro  <alex@igalia.com>
+
+       * hildon/hildon-pannable-area.c
        (hildon_pannable_area_button_press_cb),
        (hildon_pannable_area_motion_notify_cb),
        (hildon_pannable_area_button_release_cb): Added unrefs to reduce
index 33033dc..abf5223 100644 (file)
@@ -1223,6 +1223,8 @@ hildon_pannable_area_size_allocate (GtkWidget * widget,
 
   if (child && GTK_WIDGET_VISIBLE (child)) {
 
+    hildon_pannable_area_check_scrollbars (HILDON_PANNABLE_AREA (widget));
+
     hildon_pannable_area_child_allocate_calculate (widget,
                                                    allocation,
                                                    &child_allocation);