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

Unified Diff: chrome/browser/resources/settings/printing_page/cups_printers_browser_proxy.js

Issue 2915703002: Query printers for autoconf info during setup. (Closed)
Patch Set: fix test Created 3 years, 6 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/settings/printing_page/cups_printers_browser_proxy.js
diff --git a/chrome/browser/resources/settings/printing_page/cups_printers_browser_proxy.js b/chrome/browser/resources/settings/printing_page/cups_printers_browser_proxy.js
index c02a562f92b338e9ae47e3da01ac003f46170778..3af40d9758b3454d44e6e3751cbbe64007f4c0be 100644
--- a/chrome/browser/resources/settings/printing_page/cups_printers_browser_proxy.js
+++ b/chrome/browser/resources/settings/printing_page/cups_printers_browser_proxy.js
@@ -10,6 +10,7 @@
/**
* @typedef {{
* printerAddress: string,
+ * printerAutoconf: boolean,
* printerDescription: string,
* printerId: string,
* printerManufacturer: string,
@@ -46,6 +47,22 @@ var ManufacturersInfo;
*/
var ModelsInfo;
+/**
+ * @typedef {{
+ * manufacturer: string,
+ * model: string,
+ * autoconf: boolean
+ * }}
+ */
+var PrinterMakeModel;
+
+/**
+ * @typedef {{
+ * message: string
+ * }}
+ */
+var QueryFailure;
+
cr.define('settings', function() {
/** @interface */
function CupsPrintersBrowserProxy() {}
@@ -93,6 +110,12 @@ cr.define('settings', function() {
* @return {!Promise<!ModelsInfo>}
*/
getCupsPrinterModelsList: function(manufacturer) {},
+
+ /**
+ * @param {!CupsPrinterInfo} newPrinter
+ * @return {!Promise<!PrinterMakeModel>}
+ */
+ getPrinterInfo: function(newPrinter) {},
};
/**
@@ -147,6 +170,11 @@ cr.define('settings', function() {
getCupsPrinterModelsList: function(manufacturer) {
return cr.sendWithPromise('getCupsPrinterModelsList', manufacturer);
},
+
+ /** @override */
+ getPrinterInfo: function(newPrinter) {
+ return cr.sendWithPromise('getPrinterInfo', newPrinter);
+ },
};
return {

Powered by Google App Engine
This is Rietveld 408576698