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

Unified Diff: chrome/browser/resources/print_preview/data/destination_store.js

Issue 2881213003: Print Preview: Use cr.sendWithPromise for getInitialSettings (Closed)
Patch Set: Revert extra change from rebase 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/print_preview/data/destination_store.js
diff --git a/chrome/browser/resources/print_preview/data/destination_store.js b/chrome/browser/resources/print_preview/data/destination_store.js
index 72bd0b006f13ccb1988147f1a52a724640a4a6d0..116b1c64ee0f5fcb3fff3e44a513e9c1ef7009b6 100644
--- a/chrome/browser/resources/print_preview/data/destination_store.js
+++ b/chrome/browser/resources/print_preview/data/destination_store.js
@@ -1359,40 +1359,41 @@ cr.define('print_preview', function() {
* @private
*/
addEventListeners_: function() {
+ var nativeLayerEventTarget = this.nativeLayer_.getEventTarget();
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.LOCAL_DESTINATIONS_SET,
this.onLocalDestinationsSet_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.CAPABILITIES_SET,
this.onLocalDestinationCapabilitiesSet_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.GET_CAPABILITIES_FAIL,
this.onGetCapabilitiesFail_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.DESTINATIONS_RELOAD,
this.onDestinationsReload_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.PRIVET_PRINTER_CHANGED,
this.onPrivetPrinterAdded_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.PRIVET_CAPABILITIES_SET,
this.onPrivetCapabilitiesSet_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.EXTENSION_PRINTERS_ADDED,
this.onExtensionPrintersAdded_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.EXTENSION_CAPABILITIES_SET,
this.onExtensionCapabilitiesSet_.bind(this));
this.tracker_.add(
- this.nativeLayer_,
+ nativeLayerEventTarget,
print_preview.NativeLayer.EventType.PROVISIONAL_DESTINATION_RESOLVED,
this.handleProvisionalDestinationResolved_.bind(this));
},

Powered by Google App Engine
This is Rietveld 408576698