| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_PRINTING_CONTEXT_WIN_H_ | 5 #ifndef PRINTING_PRINTING_CONTEXT_WIN_H_ |
| 6 #define PRINTING_PRINTING_CONTEXT_WIN_H_ | 6 #define PRINTING_PRINTING_CONTEXT_WIN_H_ |
| 7 | 7 |
| 8 #include <ocidl.h> | 8 #include <ocidl.h> |
| 9 #include <commdlg.h> | 9 #include <commdlg.h> |
| 10 | 10 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 int max_pages, | 27 int max_pages, |
| 28 bool has_selection, | 28 bool has_selection, |
| 29 PrintSettingsCallback* callback); | 29 PrintSettingsCallback* callback); |
| 30 virtual Result UseDefaultSettings(); | 30 virtual Result UseDefaultSettings(); |
| 31 virtual Result InitWithSettings(const PrintSettings& settings); | 31 virtual Result InitWithSettings(const PrintSettings& settings); |
| 32 virtual Result NewDocument(const string16& document_name); | 32 virtual Result NewDocument(const string16& document_name); |
| 33 virtual Result NewPage(); | 33 virtual Result NewPage(); |
| 34 virtual Result PageDone(); | 34 virtual Result PageDone(); |
| 35 virtual Result DocumentDone(); | 35 virtual Result DocumentDone(); |
| 36 virtual void Cancel(); | 36 virtual void Cancel(); |
| 37 virtual void DismissDialog(); | |
| 38 virtual void ReleaseContext(); | 37 virtual void ReleaseContext(); |
| 39 virtual gfx::NativeDrawingContext context() const; | 38 virtual gfx::NativeDrawingContext context() const; |
| 40 | 39 |
| 41 #if defined(UNIT_TEST) | 40 #if defined(UNIT_TEST) |
| 42 // Sets a fake PrintDlgEx function pointer in tests. | 41 // Sets a fake PrintDlgEx function pointer in tests. |
| 43 void SetPrintDialog(HRESULT (__stdcall *print_dialog_func)(LPPRINTDLGEX)) { | 42 void SetPrintDialog(HRESULT (__stdcall *print_dialog_func)(LPPRINTDLGEX)) { |
| 44 print_dialog_func_ = print_dialog_func; | 43 print_dialog_func_ = print_dialog_func; |
| 45 } | 44 } |
| 46 #endif // defined(UNIT_TEST) | 45 #endif // defined(UNIT_TEST) |
| 47 | 46 |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 // Function pointer that defaults to PrintDlgEx. It can be changed using | 87 // Function pointer that defaults to PrintDlgEx. It can be changed using |
| 89 // SetPrintDialog() in tests. | 88 // SetPrintDialog() in tests. |
| 90 HRESULT (__stdcall *print_dialog_func_)(LPPRINTDLGEX); | 89 HRESULT (__stdcall *print_dialog_func_)(LPPRINTDLGEX); |
| 91 | 90 |
| 92 DISALLOW_COPY_AND_ASSIGN(PrintingContextWin); | 91 DISALLOW_COPY_AND_ASSIGN(PrintingContextWin); |
| 93 }; | 92 }; |
| 94 | 93 |
| 95 } // namespace printing | 94 } // namespace printing |
| 96 | 95 |
| 97 #endif // PRINTING_PRINTING_CONTEXT_WIN_H_ | 96 #endif // PRINTING_PRINTING_CONTEXT_WIN_H_ |
| OLD | NEW |