Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Side by Side Diff: runtime/bin/vmservice/client/lib/src/observatory/chart.dart

Issue 173013004: Add accumulator to allocation profiler (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | runtime/bin/vmservice/client/lib/src/observatory_elements/heap_profile.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of observatory; 5 part of observatory;
6 6
7 class GoogleChart { 7 class GoogleChart {
8 static var _api; 8 static var _api;
9 9
10 /// Get access to the JsObject containing the Google Chart API: 10 /// Get access to the JsObject containing the Google Chart API:
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 /// chart is rendered inside [element]. 86 /// chart is rendered inside [element].
87 Chart(String chartType, Element element) { 87 Chart(String chartType, Element element) {
88 _chart = new JsObject(GoogleChart.api[chartType], [element]); 88 _chart = new JsObject(GoogleChart.api[chartType], [element]);
89 } 89 }
90 90
91 /// When the user interacts with the table by clicking on columns, 91 /// When the user interacts with the table by clicking on columns,
92 /// you must call this function before [draw] so that we draw 92 /// you must call this function before [draw] so that we draw
93 /// with the current sort settings. 93 /// with the current sort settings.
94 void refreshOptionsSortInfo() { 94 void refreshOptionsSortInfo() {
95 var props = _chart.callMethod('getSortInfo'); 95 var props = _chart.callMethod('getSortInfo');
96 print(options); 96 if ((props != null) && (props['column'] != -1)) {
97 if (props != null) { 97 // Preserve current sort settings.
98 options['sortColumn'] = props['column']; 98 options['sortColumn'] = props['column'];
99 options['sortAscending'] = props['ascending']; 99 options['sortAscending'] = props['ascending'];
100 } 100 }
101 print(options);
102 } 101 }
103 102
104 /// Draw this chart using [table] and the current [options]. 103 /// Draw this chart using [table] and the current [options].
105 void draw(DataTable table) { 104 void draw(DataTable table) {
106 var jsOptions = new JsObject.jsify(options); 105 var jsOptions = new JsObject.jsify(options);
107 _chart.callMethod('draw', [table._table, jsOptions]); 106 _chart.callMethod('draw', [table._table, jsOptions]);
108 } 107 }
109 } 108 }
OLDNEW
« no previous file with comments | « no previous file | runtime/bin/vmservice/client/lib/src/observatory_elements/heap_profile.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698