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

Unified Diff: chrome/browser/resources/print_preview/data/measurement_system.js

Issue 575333002: Compile print_preview, part 2: reduce down to 260 errors (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@I_print_preview
Patch Set: Created 6 years, 3 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
Index: chrome/browser/resources/print_preview/data/measurement_system.js
diff --git a/chrome/browser/resources/print_preview/data/measurement_system.js b/chrome/browser/resources/print_preview/data/measurement_system.js
index 3eee6fa2f96dddf6bdbd8e684dbcf55f43c29f71..291f2f3f6b4a357568050616290132c748094b81 100644
--- a/chrome/browser/resources/print_preview/data/measurement_system.js
+++ b/chrome/browser/resources/print_preview/data/measurement_system.js
@@ -38,15 +38,6 @@ cr.define('print_preview', function() {
};
/**
- * Enumeration of measurement unit types.
- * @enum {number}
- */
- MeasurementSystem.UnitType = {
- METRIC: 0, // millimeters
- IMPERIAL: 1 // inches
- };
-
- /**
* Maximum resolution of local unit values.
* @type {!Object.<!print_preview.MeasurementSystem.UnitType, number>}
* @private
@@ -123,7 +114,7 @@ cr.define('print_preview', function() {
var precision = MeasurementSystem.Precision_[this.unitType_];
var roundedValue = Math.round(value / precision) * precision;
// Truncate
- return roundedValue.toFixed(
+ return +roundedValue.toFixed(
MeasurementSystem.DecimalPlaces_[this.unitType_]);
},
@@ -157,3 +148,12 @@ cr.define('print_preview', function() {
MeasurementSystem: MeasurementSystem
};
});
+
+/**
+ * Enumeration of measurement unit types.
+ * @enum {number}
+ */
+print_preview.MeasurementSystem.UnitType = {
+ METRIC: 0, // millimeters
+ IMPERIAL: 1 // inches
+};

Powered by Google App Engine
This is Rietveld 408576698