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

Side by Side Diff: chrome/browser/resources/print_preview/print_header.js

Issue 900503002: List printers managed by extensions in print preview (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 years, 10 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', function() { 5 cr.define('print_preview', function() {
6 'use strict'; 6 'use strict';
7 7
8 /** 8 /**
9 * Creates a PrintHeader object. This object encapsulates all the elements 9 * Creates a PrintHeader object. This object encapsulates all the elements
10 * and logic related to the top part of the left pane in print_preview.html. 10 * and logic related to the top part of the left pane in print_preview.html.
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
135 this.onTicketChange_.bind(this)); 135 this.onTicketChange_.bind(this));
136 }, 136 },
137 137
138 /** 138 /**
139 * Updates Print Button state. 139 * Updates Print Button state.
140 * @private 140 * @private
141 */ 141 */
142 updatePrintButtonEnabledState_: function() { 142 updatePrintButtonEnabledState_: function() {
143 this.getChildElement('button.print').disabled = 143 this.getChildElement('button.print').disabled =
144 this.destinationStore_.selectedDestination == null || 144 this.destinationStore_.selectedDestination == null ||
145 // TODO(tbarzic): Remove this when print request for extension
146 // destinations is wired up.
147 this.destinationStore_.selectedDestination.isExtension ||
145 !this.isEnabled_ || 148 !this.isEnabled_ ||
146 !this.isPrintButtonEnabled_ || 149 !this.isPrintButtonEnabled_ ||
147 !this.printTicketStore_.isTicketValid(); 150 !this.printTicketStore_.isTicketValid();
148 }, 151 },
149 152
150 /** 153 /**
151 * Updates the summary element based on the currently selected user options. 154 * Updates the summary element based on the currently selected user options.
152 * @private 155 * @private
153 */ 156 */
154 updateSummary_: function() { 157 updateSummary_: function() {
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
266 this.getChildElement('button.print').focus(); 269 this.getChildElement('button.print').focus();
267 } 270 }
268 } 271 }
269 }; 272 };
270 273
271 // Export 274 // Export
272 return { 275 return {
273 PrintHeader: PrintHeader 276 PrintHeader: PrintHeader
274 }; 277 };
275 }); 278 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/print_preview/native_layer.js ('k') | chrome/browser/ui/webui/print_preview/print_preview_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698