[sysprof] libsysprof-ui: allow copying other trees too
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [sysprof] libsysprof-ui: allow copying other trees too
- Date: Wed, 29 May 2019 22:40:31 +0000 (UTC)
commit 661df8f2787bb3bf9b442d11a3320b7b37cf32a3
Author: Christian Hergert <chergert redhat com>
Date: Mon May 20 17:49:38 2019 -0700
libsysprof-ui: allow copying other trees too
src/libsysprof-ui/sysprof-callgraph-view.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/src/libsysprof-ui/sysprof-callgraph-view.c b/src/libsysprof-ui/sysprof-callgraph-view.c
index d8ad618..87876b5 100644
--- a/src/libsysprof-ui/sysprof-callgraph-view.c
+++ b/src/libsysprof-ui/sysprof-callgraph-view.c
@@ -758,11 +758,15 @@ sysprof_callgraph_view_copy_cb (GtkWidget *widget,
if (!(toplevel = gtk_widget_get_toplevel (widget)) ||
!GTK_IS_WINDOW (toplevel) ||
- !(focus = gtk_window_get_focus (GTK_WINDOW (toplevel))) ||
- focus != GTK_WIDGET (priv->descendants_view))
+ !(focus = gtk_window_get_focus (GTK_WINDOW (toplevel))))
return;
- copy_tree_view_selection (priv->descendants_view);
+ if (focus == GTK_WIDGET (priv->descendants_view))
+ copy_tree_view_selection (priv->descendants_view);
+ else if (focus == GTK_WIDGET (priv->callers_view))
+ copy_tree_view_selection (priv->callers_view);
+ else if (focus == GTK_WIDGET (priv->functions_view))
+ copy_tree_view_selection (priv->functions_view);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]