diff options
author | Søren Sandmann Pedersen <sandmann@daimi.au.dk> | 2010-11-11 02:01:57 -0500 |
---|---|---|
committer | Søren Sandmann Pedersen <sandmann@daimi.au.dk> | 2011-06-29 02:48:22 -0400 |
commit | f1716cfe1dde7ac73475230a1aeddd4e640a8370 (patch) | |
tree | c8e918bc8b9c161ba0141a68e700a6622035e0b8 | |
parent | 9ee8d0991d3f6b6fd02db65e6121098647ec6dfb (diff) |
Delete some unused code
-rw-r--r-- | TODO | 2 | ||||
-rw-r--r-- | sysprof.c | 104 |
2 files changed, 3 insertions, 103 deletions
@@ -8,6 +8,8 @@ New UI todo: * Consider adding entries for binary files +* Cut and paste instead of screenshot window + Before 1.1: * Move perfcounter.h into sysprof namespace @@ -80,15 +80,11 @@ struct Application GtkWidget * screenshot_close_button; GtkWidget * screenshot_window; - Profile * profile; - ProfileCaller * callers; - int timeout_id; int update_screenshot_id; char * loaded_profile; - - gboolean inhibit_forced_redraw; + Profile * profile; }; static void update_screenshot_window (Application *app); @@ -540,13 +536,9 @@ enter_display_mode (Application *app) update_sensitivity (app); - app->inhibit_forced_redraw = TRUE; - fill_descendants_tree (app); gtk_widget_grab_focus (GTK_WIDGET (app->descendants_view)); - - app->inhibit_forced_redraw = FALSE; } static void @@ -1068,30 +1060,6 @@ update_screenshot_window_idle (gpointer data) gtk_text_buffer_set_text (text_buffer, "", -1); -#if 0 - if (app->descendants) - { - AddTextInfo info; - - info.max_width = 0; - info.text = g_string_new (""); - - tree_view_foreach_visible (app->descendants_view, - compute_text_width, - &info.max_width); - - tree_view_foreach_visible (app->descendants_view, - add_text, - &info); - - gtk_text_buffer_set_text (text_buffer, info.text->str, -1); - - set_monospace (app->screenshot_textview); - - g_string_free (info.text, TRUE); - } -#endif - app->update_screenshot_id = 0; if (app->screenshot_window_visible) @@ -1145,74 +1113,8 @@ on_object_selection_changed (GtkTreeSelection *selection, Application *app = data; update_screenshot_window (app); - - if (!app->inhibit_forced_redraw) - gdk_window_process_all_updates (); /* Display updated selection */ } -#if 0 -static void -really_goto_object (Application *app, - char *object) -{ - GtkTreeModel *profile_objects; - GtkTreeIter iter; - gboolean found = FALSE; - - profile_objects = gtk_tree_view_get_model (app->object_view); - - if (gtk_tree_model_get_iter_first (profile_objects, &iter)) - { - do - { - char *list_object; - - gtk_tree_model_get (profile_objects, &iter, - OBJECT_OBJECT, &list_object, - -1); - - if (list_object == object) - { - found = TRUE; - break; - } - } - while (gtk_tree_model_iter_next (profile_objects, &iter)); - } - - if (found) - { - GtkTreePath *path = - gtk_tree_model_get_path (profile_objects, &iter); - - gtk_tree_view_set_cursor (app->object_view, path, 0, FALSE); - } -} -#endif - -#if 0 -static void -goto_object (Application *app, - GtkTreeView *tree_view, - GtkTreePath *path, - gint column) -{ - GtkTreeIter iter; - GtkTreeModel *model = gtk_tree_view_get_model (tree_view); - char *object; - - if (!gtk_tree_model_get_iter (model, &iter, path)) - return; - - gtk_tree_model_get (model, &iter, column, &object, -1); - - if (!object) - return; - - really_goto_object (app, object); -} -#endif - static void on_descendants_row_activated (GtkTreeView *tree_view, GtkTreePath *path, @@ -1222,10 +1124,6 @@ on_descendants_row_activated (GtkTreeView *tree_view, Application *app = data; gpointer object; -#if 0 - goto_object (app, tree_view, path, DESCENDANTS_OBJECT); -#endif - gtk_widget_grab_focus (GTK_WIDGET (app->descendants_view)); if ((object = get_current_object (app))) |