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

Unified Diff: tracing/tracing/ui/tracks/multi_row_track.html

Issue 2776653002: [ESLint] Fix violations when enabling curly rule in eslint. (Closed)
Patch Set: rebase Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tracing/tracing/ui/tracks/model_track.html ('k') | tracing/tracing/ui/tracks/object_instance_track.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/ui/tracks/multi_row_track.html
diff --git a/tracing/tracing/ui/tracks/multi_row_track.html b/tracing/tracing/ui/tracks/multi_row_track.html
index f16139695ef24200d02830b3b58b8fac908ee392..9f6a8f2564821004431696f29ae128c4e6ed287d 100644
--- a/tracing/tracing/ui/tracks/multi_row_track.html
+++ b/tracing/tracing/ui/tracks/multi_row_track.html
@@ -84,15 +84,15 @@ tr.exportTo('tr.ui.tracks', function() {
},
set expanded(expanded) {
- if (this.expanded_ === expanded)
- return;
+ if (this.expanded_ === expanded) return;
+
this.expanded_ = expanded;
this.expandedStateChanged_();
},
onHeadingClicked_: function(e) {
- if (this.subRows.length <= 1)
- return;
+ if (this.subRows.length <= 1) return;
+
this.expanded = !this.expanded;
if (this.groupingSource_) {
@@ -131,8 +131,9 @@ tr.exportTo('tr.ui.tracks', function() {
for (var i = 0; i < this.children.length; i++) {
this.children[i].height = h;
- if (i === 0)
+ if (i === 0) {
this.children[i].arrowVisible = true;
+ }
this.children[i].expanded = this.expanded;
}
@@ -167,8 +168,8 @@ tr.exportTo('tr.ui.tracks', function() {
this.currentSubRows_ = subRows;
for (var srI = 0; srI < subRows.length; srI++) {
var subRow = subRows[srI];
- if (!subRow.length)
- continue;
+ if (!subRow.length) continue;
+
var track = this.addSubTrack_(subRow);
track.addEventListener(
'heading-clicked', this.onHeadingClicked_.bind(this));
@@ -178,8 +179,8 @@ tr.exportTo('tr.ui.tracks', function() {
},
updateHeadingAndTooltip_: function() {
- if (!Polymer.dom(this).firstChild)
- return;
+ if (!Polymer.dom(this).firstChild) return;
+
Polymer.dom(this).firstChild.heading = this.heading_;
Polymer.dom(this).firstChild.tooltip = this.tooltip_;
},
@@ -197,15 +198,14 @@ tr.exportTo('tr.ui.tracks', function() {
},
areArrayContentsSame_: function(a, b) {
- if (!a || !b)
- return false;
- if (!a.length || !b.length)
- return false;
- if (a.length !== b.length)
- return false;
+ if (!a || !b) return false;
+
+ if (!a.length || !b.length) return false;
+
+ if (a.length !== b.length) return false;
+
for (var i = 0; i < a.length; ++i) {
- if (a[i] !== b[i])
- return false;
+ if (a[i] !== b[i]) return false;
}
return true;
}
« no previous file with comments | « tracing/tracing/ui/tracks/model_track.html ('k') | tracing/tracing/ui/tracks/object_instance_track.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698