diff options
author | Chun-wei Fan <fanchunwei@src.gnome.org> | 2013-01-23 14:49:50 +0800 |
---|---|---|
committer | Chun-wei Fan <fanchunwei@src.gnome.org> | 2013-01-23 14:49:50 +0800 |
commit | 9bdc970f8dd16caed1a5b1c353394df575f8f22a (patch) | |
tree | 6f60e22eb7b64c57cbf516bde73af7741a21d7da /gtk/gtktreeview.c | |
parent | 131a68259e80d500252e69700881b2f62aea88a3 (diff) | |
download | gtk+-9bdc970f8dd16caed1a5b1c353394df575f8f22a.tar.gz |
gtk/gtktreeview: Avoid a C99ism
Declare a variable at the top of the block
Diffstat (limited to 'gtk/gtktreeview.c')
-rw-r--r-- | gtk/gtktreeview.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk/gtktreeview.c b/gtk/gtktreeview.c index f6885277c3..57592f61dd 100644 --- a/gtk/gtktreeview.c +++ b/gtk/gtktreeview.c @@ -2479,6 +2479,7 @@ gtk_tree_view_modify_column_width (GtkTreeView *tree_view, gboolean is_expand; gint n_expand_others; gint minimum, natural, natural_others; + gint expand; is_expand = gtk_tree_view_column_get_expand (column); n_expand_others = tree_view->priv->n_expand_columns - (is_expand ? 1 : 0); @@ -2516,7 +2517,7 @@ gtk_tree_view_modify_column_width (GtkTreeView *tree_view, * It is possible for the solved natural width to be less than the * minimum; in that case, we cannot let the column expand. */ - gint expand = (tree_view->priv->width - natural_others - width) / n_expand_others; + expand = (tree_view->priv->width - natural_others - width) / n_expand_others; if (minimum + expand > width) { |