Don't allocate size to invisible BinLayout children
authorAlexander Larsson <alexl@redhat.com>
Fri, 8 Jun 2012 09:29:43 +0000 (11:29 +0200)
committerAlexander Larsson <alexl@redhat.com>
Fri, 8 Jun 2012 09:34:40 +0000 (11:34 +0200)
This is similar to what other layouts do, and avoids problems with
Gtk+ actor children which warn about being allocated not enough
space.

clutter/clutter-bin-layout.c

index a1ff28a..20c3051 100644 (file)
@@ -456,6 +456,9 @@ clutter_bin_layout_allocate (ClutterLayoutManager   *manager,
       gdouble x_align, y_align;
       gboolean x_fill, y_fill, is_set;
 
+      if (!CLUTTER_ACTOR_IS_VISIBLE (child))
+        continue;
+
       meta = clutter_layout_manager_get_child_meta (manager,
                                                     container,
                                                     child);