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

Unified Diff: chrome/browser/ui/webui/settings/chromeos/cups_printers_handler.h

Issue 2545663002: Hookup the PpdProvider in the printer setup flow. (Closed)
Patch Set: address dpadpad@ comment Created 4 years 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/ui/webui/settings/chromeos/cups_printers_handler.h
diff --git a/chrome/browser/ui/webui/settings/chromeos/cups_printers_handler.h b/chrome/browser/ui/webui/settings/chromeos/cups_printers_handler.h
index b959644da24312905d2c88e1580972f2667b67bd..d62d8acca4461059bb3571246ac2c8da9325e777 100644
--- a/chrome/browser/ui/webui/settings/chromeos/cups_printers_handler.h
+++ b/chrome/browser/ui/webui/settings/chromeos/cups_printers_handler.h
@@ -9,6 +9,7 @@
#include <string>
#include <vector>
+#include "base/files/file_path.h"
#include "base/memory/weak_ptr.h"
#include "chrome/browser/ui/webui/settings/settings_page_ui_handler.h"
#include "chromeos/printing/ppd_provider.h"
@@ -88,6 +89,20 @@ class CupsPrintersHandler : public ::settings::SettingsPageUIHandler,
void OnPrintersFound(const std::vector<Printer>& printers) override;
void OnDiscoveryDone() override;
+ // Invokes debugd to add the printer to CUPS. If |ipp_everywhere| is true,
+ // automatic configuration will be attempted and |ppd_path| is ignored.
+ // |ppd_path| is the path to a Postscript Printer Description file that will
+ // be used to configure the printer capabilities. This file must be in
+ // Downloads or the PPD Cache.
+ void AddPrinterToCups(std::unique_ptr<Printer> printer,
+ const base::FilePath& ppd_path,
+ bool ipp_everywhere);
+
+ // Callback for PpdProvider::ResolveCallback.
+ void OnPPDResolved(std::unique_ptr<Printer> printer,
+ printing::PpdProvider::CallbackResultCode result,
+ base::FilePath ppd_path);
+
std::unique_ptr<chromeos::PrinterDiscoverer> printer_discoverer_;
std::unique_ptr<chromeos::printing::PpdProvider> ppd_provider_;

Powered by Google App Engine
This is Rietveld 408576698