| 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 "printing/backend/print_backend.h" | 5 #include "printing/backend/print_backend.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 | 8 |
| 9 namespace printing { | 9 namespace printing { |
| 10 | 10 |
| 11 // Provides a stubbed out PrintBackend implementation for use on ChromeOS. | 11 // Provides a stubbed out PrintBackend implementation for use on ChromeOS. |
| 12 class PrintBackendChromeOS : public PrintBackend { | 12 class PrintBackendChromeOS : public PrintBackend { |
| 13 public: | 13 public: |
| 14 PrintBackendChromeOS(); | 14 PrintBackendChromeOS(); |
| 15 virtual ~PrintBackendChromeOS() {} | |
| 16 | 15 |
| 17 // PrintBackend implementation. | 16 // PrintBackend implementation. |
| 18 virtual bool EnumeratePrinters(PrinterList* printer_list); | 17 virtual bool EnumeratePrinters(PrinterList* printer_list) OVERRIDE; |
| 18 virtual std::string GetDefaultPrinterName() OVERRIDE; |
| 19 virtual bool GetPrinterCapsAndDefaults( |
| 20 const std::string& printer_name, |
| 21 PrinterCapsAndDefaults* printer_info) OVERRIDE; |
| 22 virtual std::string GetPrinterDriverInfo( |
| 23 const std::string& printer_name) OVERRIDE; |
| 24 virtual bool IsValidPrinter(const std::string& printer_name) OVERRIDE; |
| 19 | 25 |
| 20 virtual std::string GetDefaultPrinterName(); | 26 protected: |
| 21 | 27 virtual ~PrintBackendChromeOS() {} |
| 22 virtual bool GetPrinterCapsAndDefaults(const std::string& printer_name, | |
| 23 PrinterCapsAndDefaults* printer_info); | |
| 24 | |
| 25 virtual std::string GetPrinterDriverInfo(const std::string& printer_name); | |
| 26 | |
| 27 virtual bool IsValidPrinter(const std::string& printer_name); | |
| 28 | |
| 29 private: | |
| 30 }; | 28 }; |
| 31 | 29 |
| 32 PrintBackendChromeOS::PrintBackendChromeOS() {} | 30 PrintBackendChromeOS::PrintBackendChromeOS() {} |
| 33 | 31 |
| 34 bool PrintBackendChromeOS::EnumeratePrinters(PrinterList* printer_list) { | 32 bool PrintBackendChromeOS::EnumeratePrinters(PrinterList* printer_list) { |
| 35 return true; | 33 return true; |
| 36 } | 34 } |
| 37 | 35 |
| 38 | 36 |
| 39 | 37 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 59 return true; | 57 return true; |
| 60 } | 58 } |
| 61 | 59 |
| 62 scoped_refptr<PrintBackend> PrintBackend::CreateInstance( | 60 scoped_refptr<PrintBackend> PrintBackend::CreateInstance( |
| 63 const base::DictionaryValue* print_backend_settings) { | 61 const base::DictionaryValue* print_backend_settings) { |
| 64 return new PrintBackendChromeOS(); | 62 return new PrintBackendChromeOS(); |
| 65 } | 63 } |
| 66 | 64 |
| 67 } // namespace printing | 65 } // namespace printing |
| 68 | 66 |
| OLD | NEW |