summaryrefslogtreecommitdiffstats
path: root/printing/printing_context_win.h
diff options
context:
space:
mode:
authorvitalybuka@chromium.org <vitalybuka@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-27 17:50:39 +0000
committervitalybuka@chromium.org <vitalybuka@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-03-27 17:50:39 +0000
commit97a806383bbc9e4386b2c4ea582a34ab86c014d6 (patch)
treeb7230aca3b9d4213acc0c53a4fe16dc31b14cc3c /printing/printing_context_win.h
parentc6e24e396d431af23074ba590acb99d289118c8d (diff)
downloadchromium_src-97a806383bbc9e4386b2c4ea582a34ab86c014d6.zip
chromium_src-97a806383bbc9e4386b2c4ea582a34ab86c014d6.tar.gz
chromium_src-97a806383bbc9e4386b2c4ea582a34ab86c014d6.tar.bz2
Small PrintingContextTest cleanup.
Review URL: https://codereview.chromium.org/209973003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@259929 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'printing/printing_context_win.h')
-rw-r--r--printing/printing_context_win.h14
1 files changed, 3 insertions, 11 deletions
diff --git a/printing/printing_context_win.h b/printing/printing_context_win.h
index d0cd2fb..6c1e420 100644
--- a/printing/printing_context_win.h
+++ b/printing/printing_context_win.h
@@ -40,18 +40,14 @@ class PRINTING_EXPORT PrintingContextWin : public PrintingContext {
virtual void ReleaseContext() OVERRIDE;
virtual gfx::NativeDrawingContext context() const OVERRIDE;
-#if defined(UNIT_TEST) || defined(PRINTING_IMPLEMENTATION)
- // Sets a fake PrintDlgEx function pointer in tests.
- void SetPrintDialog(HRESULT (__stdcall *print_dialog_func)(LPPRINTDLGEX)) {
- print_dialog_func_ = print_dialog_func;
- }
-#endif // defined(UNIT_TEST)
-
// Allocates the HDC for a specific DEVMODE.
static bool AllocateContext(const std::wstring& printer_name,
const DEVMODE* dev_mode,
gfx::NativeDrawingContext* context);
+ protected:
+ virtual HRESULT ShowPrintDialog(PRINTDLGEX* options);
+
private:
// Class that manages the PrintDlgEx() callbacks. This is meant to be a
// temporary object used during the Print... dialog display.
@@ -83,10 +79,6 @@ class PRINTING_EXPORT PrintingContextWin : public PrintingContext {
// The dialog box for the time it is shown.
volatile HWND dialog_box_;
- // Function pointer that defaults to PrintDlgEx. It can be changed using
- // SetPrintDialog() in tests.
- HRESULT (__stdcall *print_dialog_func_)(LPPRINTDLGEX);
-
DISALLOW_COPY_AND_ASSIGN(PrintingContextWin);
};