| 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..47fe8c248a0701681117873560c3aa86cf6758ab 100644
|
| --- a/chrome/browser/resources/print_preview/data/destination.js
|
| +++ b/chrome/browser/resources/print_preview/data/destination.js
|
| @@ -260,6 +260,15 @@ cr.define('print_preview', function() {
|
| };
|
|
|
| /**
|
| + * Special tag that denotes whether the destination is an enterprise policy
|
| + * controlled printer.
|
| + * @type {string}
|
| + * @const
|
| + * @private
|
| + */
|
| + Destination.EnterprisePrinterTag_ = '__cp__cups_enterprise_printer=true';
|
| +
|
| + /**
|
| * Enumeration of relative icon URLs for various types of destinations.
|
| * @enum {string}
|
| * @private
|
| @@ -273,7 +282,8 @@ cr.define('print_preview', function() {
|
| THIRD_PARTY: 'images/third_party.png',
|
| PDF: 'images/pdf.png',
|
| DOCS: 'images/google_doc.png',
|
| - FEDEX: 'images/third_party_fedex.png'
|
| + FEDEX: 'images/third_party_fedex.png',
|
| + ENTERPRISE: 'images/enterprise_printer.png'
|
| };
|
|
|
| Destination.prototype = {
|
| @@ -487,6 +497,9 @@ cr.define('print_preview', function() {
|
| if (this.id_ == Destination.GooglePromotedId.SAVE_AS_PDF) {
|
| return Destination.IconUrl_.PDF;
|
| }
|
| + if (this.isEnterprisePrinter) {
|
| + return Destination.IconUrl_.ENTERPRISE;
|
| + }
|
| if (this.isLocal) {
|
| return Destination.IconUrl_.LOCAL;
|
| }
|
| @@ -556,7 +569,15 @@ cr.define('print_preview', function() {
|
| */
|
| get isProvisional() {
|
| return this.provisionalType_ != Destination.ProvisionalType.NONE;
|
| - }
|
| + },
|
| +
|
| + /**
|
| + * Whether the printer is enterprise policy controlled printer.
|
| + * @return {boolean}
|
| + */
|
| + get isEnterprisePrinter() {
|
| + return arrayContains(this.tags_, Destination.EnterprisePrinterTag_);
|
| + },
|
| };
|
|
|
| // Export
|
|
|