| Index: chrome/browser/resources/print_preview/search/destination_list.js
|
| diff --git a/chrome/browser/resources/print_preview/search/destination_list.js b/chrome/browser/resources/print_preview/search/destination_list.js
|
| index 351d31184980cbe76ca4808d869d0e1ec89238c0..3d0243f3925ecd9193b6409ad10f3cf5b0c24325 100644
|
| --- a/chrome/browser/resources/print_preview/search/destination_list.js
|
| +++ b/chrome/browser/resources/print_preview/search/destination_list.js
|
| @@ -11,6 +11,8 @@ cr.define('print_preview', function() {
|
| * activated.
|
| * @param {!cr.EventTarget} eventTarget Event target to pass to destination
|
| * items for dispatching SELECT events.
|
| + * @param {!print_preview.DestinationStore} destinationStore Data store
|
| + * containing the destinations to search through.
|
| * @param {string} title Title of the destination list.
|
| * @param {?string} actionLinkLabel Optional label of the action link. If
|
| * {@code null} is provided, the action link will not be shown.
|
| @@ -19,7 +21,8 @@ cr.define('print_preview', function() {
|
| * @constructor
|
| * @extends {print_preview.Component}
|
| */
|
| - function DestinationList(eventTarget, title, actionLinkLabel, opt_showAll) {
|
| + function DestinationList(
|
| + eventTarget, destinationStore, title, actionLinkLabel, opt_showAll) {
|
| print_preview.Component.call(this);
|
|
|
| /**
|
| @@ -30,6 +33,13 @@ cr.define('print_preview', function() {
|
| this.eventTarget_ = eventTarget;
|
|
|
| /**
|
| + * Data store containing all the destinations.
|
| + * @type {!print_preview.DestinationStore}
|
| + * @private
|
| + */
|
| + this.destinationStore_ = destinationStore;
|
| +
|
| + /**
|
| * Title of the destination list.
|
| * @type {string}
|
| * @private
|
| @@ -340,7 +350,7 @@ cr.define('print_preview', function() {
|
| */
|
| renderListItem_: function(listEl, destination) {
|
| var listItem = new print_preview.DestinationListItem(
|
| - this.eventTarget_, destination, this.query_);
|
| + this.eventTarget_, this.destinationStore_, destination, this.query_);
|
| this.addChild(listItem);
|
| listItem.render(listEl);
|
| this.listItems_.push(listItem);
|
|
|