summaryrefslogtreecommitdiffstats
path: root/printing
diff options
context:
space:
mode:
authordpapad@chromium.org <dpapad@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-16 18:22:35 +0000
committerdpapad@chromium.org <dpapad@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-03-16 18:22:35 +0000
commitb10c54d852dc3dd198df86430eeeaf5325f3129b (patch)
treecdd1cd3f0f2a454e2be51a9c5cc76968b7db349c /printing
parent02ec798143ee3295b73c91593943748e8e835058 (diff)
downloadchromium_src-b10c54d852dc3dd198df86430eeeaf5325f3129b.zip
chromium_src-b10c54d852dc3dd198df86430eeeaf5325f3129b.tar.gz
chromium_src-b10c54d852dc3dd198df86430eeeaf5325f3129b.tar.bz2
Move Start/EndPage() from NewPage/PageDone()
to inside the metafile. BUG=NONE TEST=NONE Review URL: http://codereview.chromium.org/6673035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@78399 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'printing')
-rw-r--r--printing/printing_context_win.cc11
1 files changed, 5 insertions, 6 deletions
diff --git a/printing/printing_context_win.cc b/printing/printing_context_win.cc
index 467bf3c..32a44be 100644
--- a/printing/printing_context_win.cc
+++ b/printing/printing_context_win.cc
@@ -298,13 +298,11 @@ PrintingContext::Result PrintingContextWin::NewDocument(
PrintingContext::Result PrintingContextWin::NewPage() {
if (abort_printing_)
return CANCEL;
-
DCHECK(context_);
DCHECK(in_print_job_);
- // Inform the driver that the application is about to begin sending data.
- if (StartPage(context_) <= 0)
- return OnError();
+ // Intentional No-op. NativeMetafile::SafePlayback takes care of calling
+ // ::StartPage().
return OK;
}
@@ -314,8 +312,9 @@ PrintingContext::Result PrintingContextWin::PageDone() {
return CANCEL;
DCHECK(in_print_job_);
- if (EndPage(context_) <= 0)
- return OnError();
+ // Intentional No-op. NativeMetafile::SafePlayback takes care of calling
+ // ::EndPage().
+
return OK;
}