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_SERVICE_SERVICE_UTILITY_PROCESS_HOST_H_ | 5 #ifndef CHROME_SERVICE_SERVICE_UTILITY_PROCESS_HOST_H_ |
6 #define CHROME_SERVICE_SERVICE_UTILITY_PROCESS_HOST_H_ | 6 #define CHROME_SERVICE_SERVICE_UTILITY_PROCESS_HOST_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "build/build_config.h" | 9 #include "build/build_config.h" |
10 | 10 |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 base::MessageLoopProxy* client_message_loop_proxy); | 92 base::MessageLoopProxy* client_message_loop_proxy); |
93 virtual ~ServiceUtilityProcessHost(); | 93 virtual ~ServiceUtilityProcessHost(); |
94 | 94 |
95 // Starts a process to render the specified pages in the given PDF file into | 95 // Starts a process to render the specified pages in the given PDF file into |
96 // a metafile. Currently only implemented for Windows. If the PDF has fewer | 96 // a metafile. Currently only implemented for Windows. If the PDF has fewer |
97 // pages than the specified page ranges, it will render as many as available. | 97 // pages than the specified page ranges, it will render as many as available. |
98 bool StartRenderPDFPagesToMetafile( | 98 bool StartRenderPDFPagesToMetafile( |
99 const FilePath& pdf_path, | 99 const FilePath& pdf_path, |
100 const gfx::Rect& render_area, | 100 const gfx::Rect& render_area, |
101 int render_dpi, | 101 int render_dpi, |
| 102 bool autorotate, |
102 const std::vector<printing::PageRange>& page_ranges); | 103 const std::vector<printing::PageRange>& page_ranges); |
103 | 104 |
104 // Starts a process to get capabilities and defaults for the specified | 105 // Starts a process to get capabilities and defaults for the specified |
105 // printer. Used on Windows to isolate the service process from printer driver | 106 // printer. Used on Windows to isolate the service process from printer driver |
106 // crashes by executing this in a separate process. The process does not run | 107 // crashes by executing this in a separate process. The process does not run |
107 // in a sandbox. | 108 // in a sandbox. |
108 bool StartGetPrinterCapsAndDefaults(const std::string& printer_name); | 109 bool StartGetPrinterCapsAndDefaults(const std::string& printer_name); |
109 | 110 |
110 protected: | 111 protected: |
111 // Allows this method to be overridden for tests. | 112 // Allows this method to be overridden for tests. |
(...skipping 30 matching lines...) Expand all Loading... |
142 FilePath metafile_path_; | 143 FilePath metafile_path_; |
143 // The temporary folder created for the metafile. | 144 // The temporary folder created for the metafile. |
144 scoped_ptr<ScopedTempDir> scratch_metafile_dir_; | 145 scoped_ptr<ScopedTempDir> scratch_metafile_dir_; |
145 // The unique id created for the process. | 146 // The unique id created for the process. |
146 int process_id_; | 147 int process_id_; |
147 | 148 |
148 DISALLOW_COPY_AND_ASSIGN(ServiceUtilityProcessHost); | 149 DISALLOW_COPY_AND_ASSIGN(ServiceUtilityProcessHost); |
149 }; | 150 }; |
150 | 151 |
151 #endif // CHROME_SERVICE_SERVICE_UTILITY_PROCESS_HOST_H_ | 152 #endif // CHROME_SERVICE_SERVICE_UTILITY_PROCESS_HOST_H_ |
OLD | NEW |