OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 "chrome/browser/printing/win_printing_context.h" | 5 #include "chrome/browser/printing/win_printing_context.h" |
6 | 6 |
7 #include <winspool.h> | 7 #include <winspool.h> |
8 | 8 |
9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
10 #include "base/gfx/platform_device_win.h" | |
11 #include "base/time_format.h" | 10 #include "base/time_format.h" |
12 #include "chrome/browser/browser_process.h" | 11 #include "chrome/browser/browser_process.h" |
13 #include "chrome/browser/printing/print_job_manager.h" | 12 #include "chrome/browser/printing/print_job_manager.h" |
| 13 #include "skia/ext/platform_device_win.h" |
14 | 14 |
15 using base::Time; | 15 using base::Time; |
16 | 16 |
17 namespace { | 17 namespace { |
18 | 18 |
19 // Retrieves the content of a GetPrinter call. | 19 // Retrieves the content of a GetPrinter call. |
20 void GetPrinterHelper(HANDLE printer, int level, scoped_array<uint8>* buffer) { | 20 void GetPrinterHelper(HANDLE printer, int level, scoped_array<uint8>* buffer) { |
21 DWORD buf_size = 0; | 21 DWORD buf_size = 0; |
22 GetPrinter(printer, level, NULL, 0, &buf_size); | 22 GetPrinter(printer, level, NULL, 0, &buf_size); |
23 if (buf_size) { | 23 if (buf_size) { |
(...skipping 571 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
595 if (dialog_options.hDevMode != NULL) | 595 if (dialog_options.hDevMode != NULL) |
596 GlobalFree(dialog_options.hDevMode); | 596 GlobalFree(dialog_options.hDevMode); |
597 if (dialog_options.hDevNames != NULL) | 597 if (dialog_options.hDevNames != NULL) |
598 GlobalFree(dialog_options.hDevNames); | 598 GlobalFree(dialog_options.hDevNames); |
599 | 599 |
600 return hdc_ ? OK : FAILED; | 600 return hdc_ ? OK : FAILED; |
601 } | 601 } |
602 | 602 |
603 } // namespace printing | 603 } // namespace printing |
604 | 604 |
OLD | NEW |