+2014-11-20 Ryosuke Niwa <rniwa@webkit.org>
+
+ Fix misc bugs and typos in app.js
+ https://bugs.webkit.org/show_bug.cgi?id=138946
+
+ Reviewed by Benjamin Poulain.
+
+ * public/v2/app.js:
+ (App.DashboardPaneProxyForPicker._platformOrMetricIdChanged):
+ (App.ChartsController.init):
+ (App.buildPopup): Renamed from App.BuildPopup.
+ (App.InteractiveChartComponent._constructGraphIfPossible): Fixed the bug that we were calling
+ remove() on the wrong object (an array as opposed to elements in the array).
+ (App.InteractiveChartComponent._highlightedItemsChanged): Check the length of _highlights as
+ _highlights is always an array and evalutes to true.
+
2014-11-20 Ryosuke Niwa <rniwa@webkit.org>
New perf dashboard should provide UI to create a new analysis task
_platformOrMetricIdChanged: function ()
{
var self = this;
- App.BuildPopup(this.get('store'), 'choosePane', this)
+ App.buildPopup(this.get('store'), 'choosePane', this)
.then(function (platforms) { self.set('pickerData', platforms); });
}.observes('platformId', 'metricId').on('init'),
paneList: function () {
{
this._super();
var self = this;
- App.BuildPopup(this.store, 'addPaneByMetricAndPlatform').then(function (platforms) {
+ App.buildPopup(this.store, 'addPaneByMetricAndPlatform').then(function (platforms) {
self.set('platforms', platforms);
});
},
});
-App.BuildPopup = function(store, action, position)
+App.buildPopup = function(store, action, position)
{
return App.Manifest.fetch(store).then(function () {
return App.Manifest.get('platforms').map(function (platform) {
this._dots.forEach(function (dot) { dots.remove(); });
this._dots = [];
if (this._highlights)
- this._highlights.forEach(function (highlight) { _highlights.remove(); });
+ this._highlights.forEach(function (highlight) { highlight.remove(); });
this._highlights = [];
this._currentTimeSeries = chartData.current.timeSeriesByCommitTime();
var data = this._currentTimeSeriesData.filter(function (item) { return highlightedItems[item.measurement.id()]; });
- if (this._highlights)
+ if (this._highlights.length)
this._highlights.forEach(function (highlight) { highlight.remove(); });
this._highlights.push(this._clippedContainer