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 #ifndef PRINTING_BACKEND_PRINT_BACKEND_H_ | 5 #ifndef PRINTING_BACKEND_PRINT_BACKEND_H_ |
6 #define PRINTING_BACKEND_PRINT_BACKEND_H_ | 6 #define PRINTING_BACKEND_PRINT_BACKEND_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
116 const std::string& printer_name) = 0; | 116 const std::string& printer_name) = 0; |
117 | 117 |
118 // Returns true if printer_name points to a valid printer. | 118 // Returns true if printer_name points to a valid printer. |
119 virtual bool IsValidPrinter(const std::string& printer_name) = 0; | 119 virtual bool IsValidPrinter(const std::string& printer_name) = 0; |
120 | 120 |
121 // Allocates a print backend. If |print_backend_settings| is nullptr, default | 121 // Allocates a print backend. If |print_backend_settings| is nullptr, default |
122 // settings will be used. | 122 // settings will be used. |
123 static scoped_refptr<PrintBackend> CreateInstance( | 123 static scoped_refptr<PrintBackend> CreateInstance( |
124 const base::DictionaryValue* print_backend_settings); | 124 const base::DictionaryValue* print_backend_settings); |
125 | 125 |
| 126 // Returns the value of the native cups flag |
| 127 static bool GetNativeCupsEnabled(); |
| 128 |
| 129 static void SetNativeCupsEnabled(bool enabled); |
| 130 |
126 protected: | 131 protected: |
127 friend class base::RefCountedThreadSafe<PrintBackend>; | 132 friend class base::RefCountedThreadSafe<PrintBackend>; |
128 virtual ~PrintBackend(); | 133 virtual ~PrintBackend(); |
129 }; | 134 }; |
130 | 135 |
131 } // namespace printing | 136 } // namespace printing |
132 | 137 |
133 #endif // PRINTING_BACKEND_PRINT_BACKEND_H_ | 138 #endif // PRINTING_BACKEND_PRINT_BACKEND_H_ |
OLD | NEW |