| 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 CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_PRINT_PREVIEW_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_PRINT_PREVIEW_HANDLER_H_ |
| 6 #define CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_PRINT_PREVIEW_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_PRINT_PREVIEW_HANDLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/gtest_prod_util.h" | 10 #include "base/gtest_prod_util.h" |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 154 void HandleReportDestinationEvent(const base::ListValue* args); | 154 void HandleReportDestinationEvent(const base::ListValue* args); |
| 155 | 155 |
| 156 void SendInitialSettings( | 156 void SendInitialSettings( |
| 157 const std::string& default_printer, | 157 const std::string& default_printer, |
| 158 const std::string& cloud_print_data); | 158 const std::string& cloud_print_data); |
| 159 | 159 |
| 160 // Sends the printer capabilities to the Web UI. |settings_info| contains | 160 // Sends the printer capabilities to the Web UI. |settings_info| contains |
| 161 // printer capabilities information. | 161 // printer capabilities information. |
| 162 void SendPrinterCapabilities(const base::DictionaryValue& settings_info); | 162 void SendPrinterCapabilities(const base::DictionaryValue& settings_info); |
| 163 | 163 |
| 164 // Sends error notification to the Web UI when unable to return the printer |
| 165 // capabilities. |
| 166 void SendFailedToGetPrinterCapabilities(const std::string& printer_name); |
| 167 |
| 164 // Send the list of printers to the Web UI. | 168 // Send the list of printers to the Web UI. |
| 165 void SetupPrinterList(const base::ListValue& printers); | 169 void SetupPrinterList(const base::ListValue& printers); |
| 166 | 170 |
| 167 // Send whether cloud print integration should be enabled. | 171 // Send whether cloud print integration should be enabled. |
| 168 void SendCloudPrintEnabled(); | 172 void SendCloudPrintEnabled(); |
| 169 | 173 |
| 170 // Send the PDF data to the cloud to print. | 174 // Send the PDF data to the cloud to print. |
| 171 void SendCloudPrintJob(const base::DictionaryValue& settings, | 175 void SendCloudPrintJob(const base::DictionaryValue& settings, |
| 172 std::string print_ticket); | 176 std::string print_ticket); |
| 173 | 177 |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 bool has_logged_printers_count_; | 216 bool has_logged_printers_count_; |
| 213 | 217 |
| 214 // Holds the path to the print to pdf request. It is empty if no such request | 218 // Holds the path to the print to pdf request. It is empty if no such request |
| 215 // exists. | 219 // exists. |
| 216 scoped_ptr<FilePath> print_to_pdf_path_; | 220 scoped_ptr<FilePath> print_to_pdf_path_; |
| 217 | 221 |
| 218 DISALLOW_COPY_AND_ASSIGN(PrintPreviewHandler); | 222 DISALLOW_COPY_AND_ASSIGN(PrintPreviewHandler); |
| 219 }; | 223 }; |
| 220 | 224 |
| 221 #endif // CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_PRINT_PREVIEW_HANDLER_H_ | 225 #endif // CHROME_BROWSER_UI_WEBUI_PRINT_PREVIEW_PRINT_PREVIEW_HANDLER_H_ |
| OLD | NEW |