public AllocationsView(ProfileData data, DisplayOptions options) : base() { TreeView view = new TreeView (new TreeModelAdapter (new Store (data, options))); view.AppendColumn ("Cost", new CellRendererText (), "text", 1); TreeViewColumn col = new TreeViewColumn ("Class/Allocator", new CellRendererText (), "text", 0); view.AppendColumn (col); view.ExpanderColumn = col; view.Show (); Add (view); }
public StackView(ProfileData data, DisplayOptions options) { list = new StackList (data, options); ScrolledWindow sw = new ScrolledWindow (); sw.Add (list); sw.ShowAll (); Add1 (sw); detail = new StackDetail (data, options); detail.CurrentItem = list.SelectedItem; list.Selection.Changed += delegate { detail.CurrentItem = list.SelectedItem; }; Add2 (detail); Position = 200; }
public Store(ProfileData data, DisplayOptions options) : base(data, options) { if (data == null || !data.HasAllocationData) return; nodes = new List<Node> (); foreach (ProfileData.ClassItem c in data.Classes) { if (c.AllocatedBytes > 0) { total_bytes += c.AllocatedBytes; nodes.Add (new ClassNode (this, null, c)); } } }
public bool LoadProfile(string path) { this.path = path; ProfileData data = new ProfileData (path); data.ShowWrappers = Options.ShowWrappers; data.FilteredAssemblies = Options.Filters.ToArray (); Gtk.Widget view = null; if (data.HasAllocationData) view = new AllocationsView (data, Options); else if (data.HasStackData) { view = new StackView (data, Options); supports_filtering = true; } view.ShowAll (); View = view; return true; }
public ClassNode(ProfileStore store, Node parent, ProfileData.ClassItem instance) : base(store, parent) { this.instance = instance; }
public Store(ProfileData data, DisplayOptions options) : base(data, options) { nodes = new List<Node> (); foreach (StackItem item in data.StackItems) { if (item.TotalCost <= 0) continue; if (options.ShowWrappers || !item.IsWrapper) nodes.Add (new StackNode (this, null, item)); } total = data.TotalStackCost; }
public StackList(ProfileData data, DisplayOptions options) : base() { store = new Store (data, options); Model = new TreeModelAdapter (store); Selection.SelectPath (new TreePath ("0")); AppendColumn ("Percent", new CellRendererText (), "text", 1); TreeViewColumn col = new TreeViewColumn ("Method", new CellRendererText (), "text", 0); AppendColumn (col); ExpanderColumn = col; options.Changed += delegate { data.FilteredAssemblies = options.Filters.ToArray (); store = new Store (data, options); Model = new TreeModelAdapter (store); Selection.SelectPath (new TreePath ("0")); }; }
public Store(ProfileData data, DisplayOptions options, List<StackItem> items) : base(data, options) { nodes = new List<Node> (); foreach (StackItem item in items) nodes.Add (new StackNode (this, null, item)); nodes.Sort (Node.DescendingValue); total = data.TotalStackCost; }
public StackDetail(ProfileData data, DisplayOptions options) { this.data = data; this.options = options; Label callers_lbl = new Label (Mono.Unix.Catalog.GetString ("Callers")); callers_lbl.Show (); Label calls_lbl = new Label (Mono.Unix.Catalog.GetString ("Calls")); calls_lbl.Show (); callers = new PageView (); callers.Show (); calls = new PageView (); calls.Show (); AppendPage (calls, calls_lbl); AppendPage (callers, callers_lbl); }
protected ProfileStore(ProfileData data, DisplayOptions options) { this.data = data; this.options = options; }