| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 cr.define('print_preview', function() { | 5 cr.define('print_preview', function() { |
| 6 'use strict'; | 6 'use strict'; |
| 7 | 7 |
| 8 /** | 8 /** |
| 9 * Print destination data object that holds data for both local and cloud | 9 * Print destination data object that holds data for both local and cloud |
| 10 * destinations. | 10 * destinations. |
| (...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 351 var offlineMessageId; | 351 var offlineMessageId; |
| 352 if (offlineDurationMs > 31622400000.0) { // One year. | 352 if (offlineDurationMs > 31622400000.0) { // One year. |
| 353 offlineMessageId = 'offlineForYear'; | 353 offlineMessageId = 'offlineForYear'; |
| 354 } else if (offlineDurationMs > 2678400000.0) { // One month. | 354 } else if (offlineDurationMs > 2678400000.0) { // One month. |
| 355 offlineMessageId = 'offlineForMonth'; | 355 offlineMessageId = 'offlineForMonth'; |
| 356 } else if (offlineDurationMs > 604800000.0) { // One week. | 356 } else if (offlineDurationMs > 604800000.0) { // One week. |
| 357 offlineMessageId = 'offlineForWeek'; | 357 offlineMessageId = 'offlineForWeek'; |
| 358 } else { | 358 } else { |
| 359 offlineMessageId = 'offline'; | 359 offlineMessageId = 'offline'; |
| 360 } | 360 } |
| 361 return localStrings.getString(offlineMessageId); | 361 return loadTimeData.getString(offlineMessageId); |
| 362 }, | 362 }, |
| 363 | 363 |
| 364 /** | 364 /** |
| 365 * @return {number} Number of milliseconds since the epoch when the printer | 365 * @return {number} Number of milliseconds since the epoch when the printer |
| 366 * was last accessed. | 366 * was last accessed. |
| 367 */ | 367 */ |
| 368 get lastAccessTime() { | 368 get lastAccessTime() { |
| 369 return this.lastAccessTime_; | 369 return this.lastAccessTime_; |
| 370 }, | 370 }, |
| 371 | 371 |
| (...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 456 * }} | 456 * }} |
| 457 */ | 457 */ |
| 458 var Cdd = Object; | 458 var Cdd = Object; |
| 459 | 459 |
| 460 // Export | 460 // Export |
| 461 return { | 461 return { |
| 462 Destination: Destination, | 462 Destination: Destination, |
| 463 Cdd: Cdd | 463 Cdd: Cdd |
| 464 }; | 464 }; |
| 465 }); | 465 }); |
| OLD | NEW |