| 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 // <include src="../../../../ui/webui/resources/js/cr/ui/node_utils.js"> |
| 6 |
| 5 cr.define('print_preview', function() { | 7 cr.define('print_preview', function() { |
| 6 'use strict'; | 8 'use strict'; |
| 7 | 9 |
| 8 /** | 10 /** |
| 9 * Creates a PrintHeader object. This object encapsulates all the elements | 11 * 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. | 12 * and logic related to the top part of the left pane in print_preview.html. |
| 11 * @param {!print_preview.PrintTicketStore} printTicketStore Used to read | 13 * @param {!print_preview.PrintTicketStore} printTicketStore Used to read |
| 12 * information about the document. | 14 * information about the document. |
| 13 * @param {!print_preview.DestinationStore} destinationStore Used to get the | 15 * @param {!print_preview.DestinationStore} destinationStore Used to get the |
| 14 * selected destination. | 16 * selected destination. |
| (...skipping 23 matching lines...) Expand all Loading... |
| 38 * @private | 40 * @private |
| 39 */ | 41 */ |
| 40 this.isEnabled_ = true; | 42 this.isEnabled_ = true; |
| 41 | 43 |
| 42 /** | 44 /** |
| 43 * Whether the print button is enabled. | 45 * Whether the print button is enabled. |
| 44 * @type {boolean} | 46 * @type {boolean} |
| 45 * @private | 47 * @private |
| 46 */ | 48 */ |
| 47 this.isPrintButtonEnabled_ = true; | 49 this.isPrintButtonEnabled_ = true; |
| 48 }; | 50 } |
| 49 | 51 |
| 50 /** | 52 /** |
| 51 * Event types dispatched by the print header. | 53 * Event types dispatched by the print header. |
| 52 * @enum {string} | 54 * @enum {string} |
| 53 */ | 55 */ |
| 54 PrintHeader.EventType = { | 56 PrintHeader.EventType = { |
| 55 PRINT_BUTTON_CLICK: 'print_preview.PrintHeader.PRINT_BUTTON_CLICK', | 57 PRINT_BUTTON_CLICK: 'print_preview.PrintHeader.PRINT_BUTTON_CLICK', |
| 56 CANCEL_BUTTON_CLICK: 'print_preview.PrintHeader.CANCEL_BUTTON_CLICK' | 58 CANCEL_BUTTON_CLICK: 'print_preview.PrintHeader.CANCEL_BUTTON_CLICK' |
| 57 }; | 59 }; |
| 58 | 60 |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 276 this.getChildElement('button.print').focus(); | 278 this.getChildElement('button.print').focus(); |
| 277 } | 279 } |
| 278 } | 280 } |
| 279 }; | 281 }; |
| 280 | 282 |
| 281 // Export | 283 // Export |
| 282 return { | 284 return { |
| 283 PrintHeader: PrintHeader | 285 PrintHeader: PrintHeader |
| 284 }; | 286 }; |
| 285 }); | 287 }); |
| OLD | NEW |