[clutter] table-layout: Remove dead code



commit 40c345a42af3474271b8b39934a8dd808d42e65c
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Wed Mar 21 10:42:32 2012 -0400

    table-layout: Remove dead code
    
    If a column/row is expanding, n_expand has to be greater than 1.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=672557

 clutter/clutter-table-layout.c |   16 ++++------------
 1 files changed, 4 insertions(+), 12 deletions(-)
---
diff --git a/clutter/clutter-table-layout.c b/clutter/clutter-table-layout.c
index 76289a7..ab7b5b2 100644
--- a/clutter/clutter-table-layout.c
+++ b/clutter/clutter-table-layout.c
@@ -1001,12 +1001,8 @@ calculate_col_widths (ClutterTableLayout *self,
             {
               if (columns[i].expand)
                 {
-                  if (n_expand)
-                    columns[i].final_size = columns[i].pref_size
-                                          + (extra_width / n_expand);
-                  else
-                    columns[i].final_size = columns[i].pref_size
-                                          + (extra_width / priv->n_cols);
+                  columns[i].final_size = columns[i].pref_size
+                                        + (extra_width / n_expand);
                 }
               else
                 columns[i].final_size = columns[i].pref_size;
@@ -1289,12 +1285,8 @@ calculate_row_heights (ClutterTableLayout *self,
             {
               if (rows[i].expand)
                 {
-                  if (n_expand)
-                    rows[i].final_size = rows[i].pref_size
-                                       + (extra_height / n_expand);
-                  else
-                    rows[i].final_size = rows[i].pref_size
-                                       + (extra_height / priv->n_rows);
+                  rows[i].final_size = rows[i].pref_size
+                                     + (extra_height / n_expand);
                 }
               else
                 rows[i].final_size = rows[i].pref_size;



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