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

Unified Diff: tracing/tracing/ui/side_panel/side_panel_container.html

Issue 1928873003: Use Polymer.dom with many dom manipulations. (Closed) Base URL: https://github.com/catapult-project/catapult.git@polymer10-migration
Patch Set: fixes Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tracing/tracing/ui/scripting_control.html ('k') | tracing/tracing/ui/timeline_track_view.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/ui/side_panel/side_panel_container.html
diff --git a/tracing/tracing/ui/side_panel/side_panel_container.html b/tracing/tracing/ui/side_panel/side_panel_container.html
index af82c2cd0b78256f7d94327259ddcc2ba90f3ca4..743c95338ad7a478b7196fe48410a6d88fdbad85 100644
--- a/tracing/tracing/ui/side_panel/side_panel_container.html
+++ b/tracing/tracing/ui/side_panel/side_panel_container.html
@@ -149,20 +149,20 @@ Polymer({
throw new Error('Cannot activate panel: does not support this model');
if (this.activePanelType) {
- this.getLabelElementForPanelType_(
- this.activePanelType).removeAttribute('selected');
+ Polymer.dom(this.getLabelElementForPanelType_(
+ this.activePanelType)).removeAttribute('selected');
}
this.activePanelContainer_.textContent = '';
if (panelType === undefined) {
- this.removeAttribute('expanded');
+ Polymer.dom(this).removeAttribute('expanded');
this.activePanelType_ = undefined;
return;
}
- this.getLabelElementForPanelType_(panelType).
+ Polymer.dom(this.getLabelElementForPanelType_(panelType)).
setAttribute('selected', true);
- this.setAttribute('expanded', true);
+ Polymer.dom(this).setAttribute('expanded', true);
Polymer.dom(this.activePanelContainer_).appendChild(panel);
panel.rangeOfInterest = this.rangeOfInterest_;
@@ -205,7 +205,7 @@ Polymer({
var supported = panel.supportsModel(this.model);
if (this.model && supported.supported) {
supportedPanelTypes.push(panelType);
- labelEl.setAttribute('enabled', true);
+ Polymer.dom(labelEl).setAttribute('enabled', true);
labelEl.addEventListener('click', function() {
this.activePanelType =
this.activePanelType === panelType ? undefined : panelType;
@@ -222,10 +222,10 @@ Polymer({
if (previouslyActivePanelType &&
supportedPanelTypes.indexOf(previouslyActivePanelType) != -1) {
this.activePanelType = previouslyActivePanelType;
- this.setAttribute('expanded', true);
+ Polymer.dom(this).setAttribute('expanded', true);
} else {
this.activePanelContainer_.textContent = '';
- this.removeAttribute('expanded');
+ Polymer.dom(this).removeAttribute('expanded');
}
},
« no previous file with comments | « tracing/tracing/ui/scripting_control.html ('k') | tracing/tracing/ui/timeline_track_view.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698