inspector: Update all statistics in same place
This commit is contained in:
@ -91,6 +91,8 @@ add_type_count (GtkInspectorStatistics *sl, GType type)
|
|||||||
self = g_type_get_instance_count (type);
|
self = g_type_get_instance_count (type);
|
||||||
cumulative += self;
|
cumulative += self;
|
||||||
|
|
||||||
|
data->self1 = data->self2;
|
||||||
|
data->cumulative1 = data->cumulative2;
|
||||||
data->self2 = self;
|
data->self2 = self;
|
||||||
data->cumulative2 = cumulative;
|
data->cumulative2 = cumulative;
|
||||||
|
|
||||||
@ -123,13 +125,6 @@ refresh_clicked (GtkWidget *button, GtkInspectorStatistics *sl)
|
|||||||
TypeData *data;
|
TypeData *data;
|
||||||
GtkTreeIter treeiter;
|
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)
|
if (sl->priv->snapshot_count == 0)
|
||||||
{
|
{
|
||||||
gtk_tree_view_column_set_visible (sl->priv->column_self2, TRUE);
|
gtk_tree_view_column_set_visible (sl->priv->column_self2, TRUE);
|
||||||
|
Reference in New Issue
Block a user