OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_RENDERER_PRINT_WEB_VIEW_HELPER_H_ | 5 #ifndef CHROME_RENDERER_PRINT_WEB_VIEW_HELPER_H_ |
6 #define CHROME_RENDERER_PRINT_WEB_VIEW_HELPER_H_ | 6 #define CHROME_RENDERER_PRINT_WEB_VIEW_HELPER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 // request and is filled into the |prepare| argument. | 171 // request and is filled into the |prepare| argument. |
172 // Used only for native printing workflow. | 172 // Used only for native printing workflow. |
173 bool InitPrintSettingsAndPrepareFrame( | 173 bool InitPrintSettingsAndPrepareFrame( |
174 WebKit::WebFrame* frame, | 174 WebKit::WebFrame* frame, |
175 const WebKit::WebNode& node, | 175 const WebKit::WebNode& node, |
176 scoped_ptr<PrepareFrameAndViewForPrint>* prepare); | 176 scoped_ptr<PrepareFrameAndViewForPrint>* prepare); |
177 | 177 |
178 // Update the current print settings with new |job_settings|. |job_settings| | 178 // Update the current print settings with new |job_settings|. |job_settings| |
179 // dictionary contains print job details such as printer name, number of | 179 // dictionary contains print job details such as printer name, number of |
180 // copies, page range, etc. | 180 // copies, page range, etc. |
181 bool UpdatePrintSettings(const base::DictionaryValue& job_settings, | 181 bool UpdatePrintSettings(WebKit::WebFrame* frame, |
| 182 const WebKit::WebNode& node, |
| 183 const base::DictionaryValue& passed_job_settings, |
182 bool generating_preview); | 184 bool generating_preview); |
183 | 185 |
184 // Get final print settings from the user. | 186 // Get final print settings from the user. |
185 // Return false if the user cancels or on error. | 187 // Return false if the user cancels or on error. |
186 bool GetPrintSettingsFromUser(WebKit::WebFrame* frame, | 188 bool GetPrintSettingsFromUser(WebKit::WebFrame* frame, |
187 int expected_pages_count, | 189 int expected_pages_count, |
188 bool use_browser_overlays); | 190 bool use_browser_overlays); |
189 | 191 |
190 // Page Printing / Rendering ------------------------------------------------ | 192 // Page Printing / Rendering ------------------------------------------------ |
191 | 193 |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
426 | 428 |
427 State state_; | 429 State state_; |
428 }; | 430 }; |
429 | 431 |
430 PrintPreviewContext print_preview_context_; | 432 PrintPreviewContext print_preview_context_; |
431 | 433 |
432 DISALLOW_COPY_AND_ASSIGN(PrintWebViewHelper); | 434 DISALLOW_COPY_AND_ASSIGN(PrintWebViewHelper); |
433 }; | 435 }; |
434 | 436 |
435 #endif // CHROME_RENDERER_PRINT_WEB_VIEW_HELPER_H_ | 437 #endif // CHROME_RENDERER_PRINT_WEB_VIEW_HELPER_H_ |
OLD | NEW |