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

Unified Diff: dashboard/dashboard/elements/chart-container.html

Issue 2294873003: Revert of [polymer] - Sort series data before adding to legend. (Closed) Base URL: https://github.com/catapult-project/catapult.git@master
Patch Set: Created 4 years, 4 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dashboard/dashboard/elements/chart-container.html
diff --git a/dashboard/dashboard/elements/chart-container.html b/dashboard/dashboard/elements/chart-container.html
index 5cef84d497770ec5a6ca182cfda6600af9d19350..00cfacb5c4c76b656d481d462ed79f9a36b3a40f 100644
--- a/dashboard/dashboard/elements/chart-container.html
+++ b/dashboard/dashboard/elements/chart-container.html
@@ -892,19 +892,7 @@
this.json['error_bars'][nextIndex] = newJson['error_bars'][index];
}
- // Sort the series by path.
- var sortedSeriesArray = [];
- for (var k in newSeries) {
- sortedSeriesArray.push([parseInt(k), newSeries[k]]);
- }
- var unsortedSeriesArray = sortedSeriesArray.slice().sort(
- (a, b) => a[0] - b[0]);
- sortedSeriesArray.sort((a, b) => a[1].path.localeCompare(b[1].path));
- var sortedSeries = {};
- for (var i = 0; i < sortedSeriesArray.length; i++) {
- sortedSeries[unsortedSeriesArray[i][0]] = sortedSeriesArray[i][1];
- }
- this.updateForNewSeries(sortedSeries, isSelected);
+ this.updateForNewSeries(newSeries, isSelected);
},
/**
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698