Move commits viewer to the end of details view
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 6 Feb 2015 01:23:31 +0000 (01:23 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 6 Feb 2015 01:23:31 +0000 (01:23 +0000)
https://bugs.webkit.org/show_bug.cgi?id=141315

Rubber-stamped by Andreas Kling.

Show the difference instead of the old value per kling's request.

* public/v2/app.js:
(App.PaneController._updateDetails):
* public/v2/index.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@179731 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Websites/perf.webkit.org/ChangeLog
Websites/perf.webkit.org/public/v2/app.js
Websites/perf.webkit.org/public/v2/index.html

index f2ac8c0..eb9a7d2 100644 (file)
@@ -3,6 +3,19 @@
         Move commits viewer to the end of details view
         https://bugs.webkit.org/show_bug.cgi?id=141315
 
+        Rubber-stamped by Andreas Kling.
+
+        Show the difference instead of the old value per kling's request.
+
+        * public/v2/app.js:
+        (App.PaneController._updateDetails):
+        * public/v2/index.html:
+
+2015-02-05  Ryosuke Niwa  <rniwa@webkit.org>
+
+        Move commits viewer to the end of details view
+        https://bugs.webkit.org/show_bug.cgi?id=141315
+
         Reviewed by Andreas Kling.
 
         Improved the way list of commits are shown per kling's request.
index 788ac45..ec459e0 100755 (executable)
@@ -763,10 +763,14 @@ App.PaneController = Ember.ObjectController.extend({
         }
 
         var chartData = this.get('chartData');
+        var valueDiff = oldMeasurement ? chartData.formatter(currentMeasurement.mean() - oldMeasurement.mean()) : null;
+        if (valueDiff && valueDiff > 0)
+            valueDiff = '+' + valueDiff;
+
         this.set('details', Ember.Object.create({
             status: this._computeStatus(currentPoint),
             currentValue: chartData.formatter(currentMeasurement.mean()),
-            oldValue: oldMeasurement ? chartData.formatter(oldMeasurement.mean()) : null,
+            valueDiff: valueDiff,
             buildNumber: buildNumber,
             buildURL: buildURL,
             buildTime: currentMeasurement.formattedBuildTime(),
index 508e18d..6daddce 100755 (executable)
                     <th>Current</th>
                     <td>
                         {{details.currentValue}} {{chartData.unit}}
-                        {{#if details.oldValue}}
-                            (from {{details.oldValue}} {{chartData.unit}})
+                        {{#if details.valueDiff}}
+                            ({{details.valueDiff}} {{chartData.unit}})
                         {{/if}}
                         {{#if details.status.label}}
                             <br>