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

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

Issue 2617663002: WIP: run clang-format-js on lots of things (Closed)
Patch Set: merge Created 3 years, 11 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/destination.js
diff --git a/chrome/browser/resources/print_preview/data/destination.js b/chrome/browser/resources/print_preview/data/destination.js
index 91aa8ecc8b7781d10c80d1c2b15459e851274144..5f91dc28037631e2fdd4de6103a369752b46ccfc 100644
--- a/chrome/browser/resources/print_preview/data/destination.js
+++ b/chrome/browser/resources/print_preview/data/destination.js
@@ -62,8 +62,8 @@ cr.define('print_preview', function() {
* for the destination.
* @constructor
*/
- function Destination(id, type, origin, displayName, isRecent,
- connectionStatus, opt_params) {
+ function Destination(
+ id, type, origin, displayName, isRecent, connectionStatus, opt_params) {
/**
* ID of the destination.
* @private {string}
@@ -141,8 +141,8 @@ cr.define('print_preview', function() {
* accessed.
* @private {number}
*/
- this.lastAccessTime_ = (opt_params && opt_params.lastAccessTime) ||
- Date.now();
+ this.lastAccessTime_ =
+ (opt_params && opt_params.lastAccessTime) || Date.now();
/**
* Whether the user has accepted the terms-of-service for the print
@@ -180,12 +180,13 @@ cr.define('print_preview', function() {
* @private {Destination.ProvisionalType}
*/
this.provisionalType_ = (opt_params && opt_params.provisionalType) ||
- Destination.ProvisionalType.NONE;
+ Destination.ProvisionalType.NONE;
- assert(this.provisionalType_ !=
- Destination.ProvisionalType.NEEDS_USB_PERMISSON ||
- this.isExtension,
- 'Provisional USB destination only supprted with extension origin.');
+ assert(
+ this.provisionalType_ !=
+ Destination.ProvisionalType.NEEDS_USB_PERMISSON ||
+ this.isExtension,
+ 'Provisional USB destination only supprted with extension origin.');
};
/**
@@ -193,10 +194,8 @@ cr.define('print_preview', function() {
* @type {!Array<string>}
* @const
*/
- Destination.LOCATION_TAG_PREFIXES = [
- '__cp__location=',
- '__cp__printer-location='
- ];
+ Destination.LOCATION_TAG_PREFIXES =
+ ['__cp__location=', '__cp__printer-location='];
/**
* Enumeration of Google-promoted destination IDs.
@@ -329,10 +328,9 @@ cr.define('print_preview', function() {
/** @return {boolean} Whether the destination is local or cloud-based. */
get isLocal() {
return this.origin_ == Destination.Origin.LOCAL ||
- this.origin_ == Destination.Origin.EXTENSION ||
- (this.origin_ == Destination.Origin.PRIVET &&
- this.connectionStatus_ !=
- Destination.ConnectionStatus.UNREGISTERED);
+ this.origin_ == Destination.Origin.EXTENSION ||
+ (this.origin_ == Destination.Origin.PRIVET &&
+ this.connectionStatus_ != Destination.ConnectionStatus.UNREGISTERED);
},
/** @return {boolean} Whether the destination is a Privet local printer */
@@ -444,9 +442,12 @@ cr.define('print_preview', function() {
/** @return {boolean} Whether the destination is considered offline. */
get isOffline() {
- return arrayContains([print_preview.Destination.ConnectionStatus.OFFLINE,
- print_preview.Destination.ConnectionStatus.DORMANT],
- this.connectionStatus_);
+ return arrayContains(
+ [
+ print_preview.Destination.ConnectionStatus.OFFLINE,
+ print_preview.Destination.ConnectionStatus.DORMANT
+ ],
+ this.connectionStatus_);
},
/** @return {string} Human readable status for offline destination. */

Powered by Google App Engine
This is Rietveld 408576698