diff --git a/src/AddIns/Misc/Profiler/Controller/Data/CallTreeNode.cs b/src/AddIns/Misc/Profiler/Controller/Data/CallTreeNode.cs
index 1c36a3bf2f..ca61b51764 100644
--- a/src/AddIns/Misc/Profiler/Controller/Data/CallTreeNode.cs
+++ b/src/AddIns/Misc/Profiler/Controller/Data/CallTreeNode.cs
@@ -60,6 +60,15 @@ namespace ICSharpCode.Profiler.Controller.Data
}
}
+ ///
+ /// Gets whether this call is user code.
+ ///
+ public virtual bool IsUserCode {
+ get {
+ return this.NameMapping.Id > 0;
+ }
+ }
+
///
/// Gets whether the function call started in a previous data set that's not selected.
///
diff --git a/src/AddIns/Misc/Profiler/Frontend/AddIn/Src/Views/ProfilerView.xaml b/src/AddIns/Misc/Profiler/Frontend/AddIn/Src/Views/ProfilerView.xaml
index 584d149085..65b9fc792f 100644
--- a/src/AddIns/Misc/Profiler/Frontend/AddIn/Src/Views/ProfilerView.xaml
+++ b/src/AddIns/Misc/Profiler/Frontend/AddIn/Src/Views/ProfilerView.xaml
@@ -25,7 +25,7 @@
-
+
diff --git a/src/AddIns/Misc/Profiler/Frontend/Controls/QueryView.xaml.cs b/src/AddIns/Misc/Profiler/Frontend/Controls/QueryView.xaml.cs
index 9f9c1cdb51..71f6de489c 100644
--- a/src/AddIns/Misc/Profiler/Frontend/Controls/QueryView.xaml.cs
+++ b/src/AddIns/Misc/Profiler/Frontend/Controls/QueryView.xaml.cs
@@ -294,6 +294,23 @@ namespace ICSharpCode.Profiler.Controls
this.Invalidate();
}
+ void BtnExpandHotPathSubtreeClick(object sender, RoutedEventArgs e)
+ {
+ foreach (CallTreeNodeViewModel node in this.SelectedItems.ToArray()) {
+ ExpandHotPathItems(node);
+ }
+ }
+
+ void ExpandHotPathItems(CallTreeNodeViewModel parent)
+ {
+ if (parent.HotPathIndicatorVisibility == Visibility.Visible) {
+ parent.IsExpanded = true;
+
+ foreach (CallTreeNodeViewModel node in parent.Children)
+ ExpandHotPathItems(node);
+ }
+ }
+
public ContextMenu TreeViewContextMenu {
get { return this.treeView.ContextMenu; }
set { this.treeView.ContextMenu = this.ringDiagram.ContextMenu = value; }