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

Side by Side Diff: chrome/browser/resources/print_preview/data/ticket_items/landscape.js

Issue 2861713004: Print Preview: Fix compile errors in settings/ directory (Closed)
Patch Set: Address comments and fix remaining lint errors Created 3 years, 7 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 unified diff | Download patch
OLDNEW
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.ticket_items', function() { 5 cr.define('print_preview.ticket_items', function() {
6 'use strict'; 6 'use strict';
7 7
8 /** 8 /**
9 * Landscape ticket item whose value is a {@code boolean} that indicates 9 * Landscape ticket item whose value is a {@code boolean} that indicates
10 * whether the document should be printed in landscape orientation. 10 * whether the document should be printed in landscape orientation.
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 }, 96 },
97 97
98 /** @override */ 98 /** @override */
99 updateValueInternal: function(value) { 99 updateValueInternal: function(value) {
100 var updateMargins = !this.isValueEqual(value); 100 var updateMargins = !this.isValueEqual(value);
101 print_preview.ticket_items.TicketItem.prototype.updateValueInternal.call( 101 print_preview.ticket_items.TicketItem.prototype.updateValueInternal.call(
102 this, value); 102 this, value);
103 if (updateMargins) { 103 if (updateMargins) {
104 // Reset the user set margins when page orientation changes. 104 // Reset the user set margins when page orientation changes.
105 this.marginsType_.updateValue( 105 this.marginsType_.updateValue(
106 print_preview.ticket_items.MarginsType.Value.DEFAULT); 106 print_preview.ticket_items.MarginsTypeValue.DEFAULT);
107 this.customMargins_.updateValue(null); 107 this.customMargins_.updateValue(null);
108 } 108 }
109 }, 109 },
110 110
111 /** 111 /**
112 * @return {boolean} Whether capability contains the |value|. 112 * @return {boolean} Whether capability contains the |value|.
113 * @param {string} value Option to check. 113 * @param {string} value Option to check.
114 */ 114 */
115 hasOption: function(value) { 115 hasOption: function(value) {
116 var cap = this.getPageOrientationCapability_(); 116 var cap = this.getPageOrientationCapability_();
(...skipping 16 matching lines...) Expand all
133 dest.capabilities.printer.page_orientation) || 133 dest.capabilities.printer.page_orientation) ||
134 null; 134 null;
135 } 135 }
136 }; 136 };
137 137
138 // Export 138 // Export
139 return { 139 return {
140 Landscape: Landscape 140 Landscape: Landscape
141 }; 141 };
142 }); 142 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698