inspector: Update all statistics in same place

This commit is contained in:
Benjamin Otte 2014-10-13 10:09:48 +02:00
parent d123ea579f
commit 8d06b84670

View File

@ -91,6 +91,8 @@ add_type_count (GtkInspectorStatistics *sl, GType type)
self = g_type_get_instance_count (type);
cumulative += self;
data->self1 = data->self2;
data->cumulative1 = data->cumulative2;
data->self2 = self;
data->cumulative2 = cumulative;
@ -123,13 +125,6 @@ refresh_clicked (GtkWidget *button, GtkInspectorStatistics *sl)
TypeData *data;
GtkTreeIter treeiter;
g_hash_table_iter_init (&iter, sl->priv->counts);
while (g_hash_table_iter_next (&iter, NULL, (gpointer *)&data))
{
data->self1 = data->self2;
data->cumulative1 = data->cumulative2;
}
if (sl->priv->snapshot_count == 0)
{
gtk_tree_view_column_set_visible (sl->priv->column_self2, TRUE);