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

Side by Side Diff: tracing/tracing/ui/analysis/memory_dump_heap_details_pane.html

Issue 1923953003: [polymer] Switches .appendChild() to Polymer.dom()...appendChild() (Closed) Base URL: git@github.com:catapult-project/catapult.git@polymer10-migration
Patch Set: Created 4 years, 7 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
OLDNEW
1 <!DOCTYPE html> 1 <!DOCTYPE html>
2 <!-- 2 <!--
3 Copyright 2015 The Chromium Authors. All rights reserved. 3 Copyright 2015 The Chromium Authors. All rights reserved.
4 Use of this source code is governed by a BSD-style license that can be 4 Use of this source code is governed by a BSD-style license that can be
5 found in the LICENSE file. 5 found in the LICENSE file.
6 --> 6 -->
7 7
8 <link rel="import" href="/tracing/base/color_scheme.html"> 8 <link rel="import" href="/tracing/base/color_scheme.html">
9 <link rel="import" href="/tracing/base/iteration_helpers.html"> 9 <link rel="import" href="/tracing/base/iteration_helpers.html">
10 <link rel="import" href="/tracing/base/multi_dimensional_view.html"> 10 <link rel="import" href="/tracing/base/multi_dimensional_view.html">
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 } else { 144 } else {
145 symbolEl.textContent = CIRCLED_LATIN_CAPITAL_LETTER_T; 145 symbolEl.textContent = CIRCLED_LATIN_CAPITAL_LETTER_T;
146 symbolEl.title = 'Object type'; 146 symbolEl.title = 'Object type';
147 symbolColorName = 'heap_dump_object_type'; 147 symbolColorName = 'heap_dump_object_type';
148 } 148 }
149 symbolEl.style.color = 149 symbolEl.style.color =
150 tr.b.ColorScheme.getColorForReservedNameAsString(symbolColorName); 150 tr.b.ColorScheme.getColorForReservedNameAsString(symbolColorName);
151 symbolEl.style.paddingRight = '4px'; 151 symbolEl.style.paddingRight = '4px';
152 symbolEl.style.cursor = 'help'; 152 symbolEl.style.cursor = 'help';
153 symbolEl.style.weight = 'bold'; 153 symbolEl.style.weight = 'bold';
154 titleEl.appendChild(symbolEl); 154 Polymer.dom(titleEl).appendChild(symbolEl);
155 155
156 titleEl.appendChild(document.createTextNode(title)); 156 Polymer.dom(titleEl).appendChild(document.createTextNode(title));
157 157
158 return titleEl; 158 return titleEl;
159 } 159 }
160 }; 160 };
161 161
162 var COLUMN_RULES = [ 162 var COLUMN_RULES = [
163 { 163 {
164 importance: 0, 164 importance: 0,
165 columnConstructor: tr.ui.analysis.NumericMemoryColumn 165 columnConstructor: tr.ui.analysis.NumericMemoryColumn
166 } 166 }
167 ]; 167 ];
168 168
169 Polymer({ 169 Polymer({
170 is: 'tr-ui-a-memory-dump-heap-details-pane', 170 is: 'tr-ui-a-memory-dump-heap-details-pane',
171 behaviors: [Catapult.tr_ui_a_stacked_pane], 171 behaviors: [Catapult.tr_ui_a_stacked_pane],
172 172
173 created: function() { 173 created: function() {
174 this.heapDumps_ = undefined; 174 this.heapDumps_ = undefined;
175 this.aggregationMode_ = undefined; 175 this.aggregationMode_ = undefined;
176 this.viewMode_ = undefined; 176 this.viewMode_ = undefined;
177 }, 177 },
178 178
179 ready: function() { 179 ready: function() {
180 this.$.table.selectionMode = tr.ui.b.TableFormat.SelectionMode.ROW; 180 this.$.table.selectionMode = tr.ui.b.TableFormat.SelectionMode.ROW;
181 this.$.info_bar.message = 'Note: Values displayed in the heavy view ' + 181 this.$.info_bar.message = 'Note: Values displayed in the heavy view ' +
182 'are lower bounds (except for the root).'; 182 'are lower bounds (except for the root).';
183 183
184 this.$.view_mode_container.appendChild(tr.ui.b.createSelector( 184 Polymer.dom(this.$.view_mode_container).appendChild(
185 this, 'viewMode', 'memoryDumpHeapDetailsPane.viewMode', 185 tr.ui.b.createSelector(this, 'viewMode',
186 tr.b.MultiDimensionalViewType.TOP_DOWN_TREE_VIEW, 186 'memoryDumpHeapDetailsPane.viewMode',
187 [ 187 tr.b.MultiDimensionalViewType.TOP_DOWN_TREE_VIEW, [
188 { 188 {
189 label: 'Top-down (Tree)', 189 label: 'Top-down (Tree)',
190 value: tr.b.MultiDimensionalViewType.TOP_DOWN_TREE_VIEW 190 value: tr.b.MultiDimensionalViewType.TOP_DOWN_TREE_VIEW
191 }, 191 },
192 { 192 {
193 label: 'Top-down (Heavy)', 193 label: 'Top-down (Heavy)',
194 value: tr.b.MultiDimensionalViewType.TOP_DOWN_HEAVY_VIEW 194 value: tr.b.MultiDimensionalViewType.TOP_DOWN_HEAVY_VIEW
195 }, 195 },
196 { 196 {
197 label: 'Bottom-up (Heavy)', 197 label: 'Bottom-up (Heavy)',
198 value: tr.b.MultiDimensionalViewType.BOTTOM_UP_HEAVY_VIEW 198 value: tr.b.MultiDimensionalViewType.BOTTOM_UP_HEAVY_VIEW
199 } 199 }
200 ])); 200 ]));
201 }, 201 },
202 202
203 /** 203 /**
204 * Sets the heap dumps and schedules rebuilding the pane. 204 * Sets the heap dumps and schedules rebuilding the pane.
205 * 205 *
206 * The provided value should be a chronological list of heap dumps. All 206 * The provided value should be a chronological list of heap dumps. All
207 * dumps are assumed to belong to the same process and belong to the same 207 * dumps are assumed to belong to the same process and belong to the same
208 * allocator. Example: 208 * allocator. Example:
209 * 209 *
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
398 var columns = [titleColumn].concat(numericColumns); 398 var columns = [titleColumn].concat(numericColumns);
399 return columns; 399 return columns;
400 } 400 }
401 }); 401 });
402 402
403 return { 403 return {
404 RowDimension: RowDimension // Exported for testing. 404 RowDimension: RowDimension // Exported for testing.
405 }; 405 };
406 }); 406 });
407 </script> 407 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698