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

Side by Side Diff: tracing/tracing/ui/extras/about_tracing/profiling_view.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 (c) 2013 The Chromium Authors. All rights reserved. 3 Copyright (c) 2013 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/base64.html"> 8 <link rel="import" href="/tracing/base/base64.html">
9 <link rel="import" href="/tracing/importer/import.html"> 9 <link rel="import" href="/tracing/importer/import.html">
10 <link rel="import" href="/tracing/ui/base/file.html"> 10 <link rel="import" href="/tracing/ui/base/file.html">
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 * @constructor 71 * @constructor
72 * @extends {HTMLUnknownElement} 72 * @extends {HTMLUnknownElement}
73 */ 73 */
74 var ProfilingView = tr.ui.b.define('x-profiling-view'); 74 var ProfilingView = tr.ui.b.define('x-profiling-view');
75 var THIS_DOC = document.currentScript.ownerDocument; 75 var THIS_DOC = document.currentScript.ownerDocument;
76 76
77 ProfilingView.prototype = { 77 ProfilingView.prototype = {
78 __proto__: HTMLUnknownElement.prototype, 78 __proto__: HTMLUnknownElement.prototype,
79 79
80 decorate: function(tracingControllerClient) { 80 decorate: function(tracingControllerClient) {
81 Polymer.dom(this).appendChild(tr.ui.b.instantiateTemplate('#profiling-view -template', 81 Polymer.dom(this).appendChild(
82 THIS_DOC)); 82 tr.ui.b.instantiateTemplate('#profiling-view-template', THIS_DOC));
83 83
84 this.timelineView_ = this.querySelector('tr-ui-timeline-view'); 84 this.timelineView_ = this.querySelector('tr-ui-timeline-view');
85 this.infoBarGroup_ = this.querySelector('tr-ui-b-info-bar-group'); 85 this.infoBarGroup_ = this.querySelector('tr-ui-b-info-bar-group');
86 86
87 // Detach the buttons. We will reattach them to the timeline view. 87 // Detach the buttons. We will reattach them to the timeline view.
88 // TODO(nduca): Make timeline-view have a content select="x-buttons" 88 // TODO(nduca): Make timeline-view have a content select="x-buttons"
89 // that pulls in any buttons. 89 // that pulls in any buttons.
90 this.recordButton_ = this.querySelector('#record-button'); 90 this.recordButton_ = this.querySelector('#record-button');
91 this.loadButton_ = this.querySelector('#load-button'); 91 this.loadButton_ = this.querySelector('#load-button');
92 this.saveButton_ = this.querySelector('#save-button'); 92 this.saveButton_ = this.querySelector('#save-button');
93 93
94 var buttons = this.querySelector('x-timeline-view-buttons'); 94 var buttons = this.querySelector('x-timeline-view-buttons');
95 buttons.parentElement.removeChild(buttons); 95 buttons.parentElement.removeChild(buttons);
96 this.timelineView_.leftControls.appendChild(buttons); 96 Polymer.dom(this.timelineView_.leftControls).appendChild(buttons);
97 this.initButtons_(); 97 this.initButtons_();
98 98
99 this.timelineView_.hotkeyController.addHotKey(new tr.ui.b.HotKey({ 99 this.timelineView_.hotkeyController.addHotKey(new tr.ui.b.HotKey({
100 eventType: 'keypress', 100 eventType: 'keypress',
101 keyCode: 'r'.charCodeAt(0), 101 keyCode: 'r'.charCodeAt(0),
102 callback: function(e) { 102 callback: function(e) {
103 this.beginRecording(); 103 this.beginRecording();
104 event.stopPropagation(); 104 event.stopPropagation();
105 }, 105 },
106 thisArg: this 106 thisArg: this
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 }); 360 });
361 return false; 361 return false;
362 } 362 }
363 }; 363 };
364 364
365 return { 365 return {
366 ProfilingView: ProfilingView 366 ProfilingView: ProfilingView
367 }; 367 };
368 }); 368 });
369 </script> 369 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698