Chromium Code Reviews| Index: chrome/browser/resources/print_preview/data/ticket_items/scaling.js |
| diff --git a/chrome/browser/resources/print_preview/data/ticket_items/scaling.js b/chrome/browser/resources/print_preview/data/ticket_items/scaling.js |
| index c7f3a37fb58fbc24f7c247fa2db982dd3a15bcf1..b5961dcec7cc96ebf07982f2b8889721ebe4ec0e 100644 |
| --- a/chrome/browser/resources/print_preview/data/ticket_items/scaling.js |
| +++ b/chrome/browser/resources/print_preview/data/ticket_items/scaling.js |
| @@ -45,26 +45,14 @@ cr.define('print_preview.ticket_items', function() { |
| /** @override */ |
| wouldValueBeValid: function(value) { |
| - if (/[^\d]+/.test(value)) { |
| - return false; |
| - } |
| - var scaling = parseInt(value, 10); |
| - return scaling >= Scaling.MIN_VAL && scaling <= Scaling.MAX_VAL; |
| - }, |
| + return true; |
|
dpapad
2017/02/27 21:56:02
Is this resulting in the same behavior as before?
rbpotter
2017/02/28 00:12:59
It should be. This function was only called in isV
|
| + }, |
| /** @override */ |
| isValueEqual: function(value) { |
| return this.getValueAsNumber() == value; |
| }, |
| - /** |
| - * @param {number} The desired scaling percentage. |
| - * @return {number} Nearest valid scaling percentage |
| - */ |
| - getNearestValidValue: function(value) { |
| - return Math.min(Math.max(value, Scaling.MIN_VAL), Scaling.MAX_VAL); |
| - }, |
| - |
| /** @override */ |
| isCapabilityAvailable: function() { |
| // This is not a function of the printer, but should be disabled if we are |