diff options
author | dan sinclair <dsinclair@chromium.org> | 2017-05-12 21:22:08 -0400 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-05-15 15:40:43 +0000 |
commit | d2afac1e9200478997e308eecc582a073185d7ab (patch) | |
tree | 1ec1a2c69168cb2ab3f1418fae0e9f1c754cebdb /core/fxge/win32/fx_win32_print.cpp | |
parent | 017ebba6940e0fe5ff39122c033600f88f24539a (diff) | |
download | pdfium-d2afac1e9200478997e308eecc582a073185d7ab.tar.xz |
Convert CPSOutput to an IFX_WriteStream
This Cl updates CPSOutput to inherit from IFX_WriteStream and converts
the CFX_PSRenderer to accept an IFX_WriteStream instead of a CPSOutput.
Change-Id: Ibde5c7da1c2f6df0a10cb6e9a470e18fbab167b8
Reviewed-on: https://pdfium-review.googlesource.com/5431
Reviewed-by: Nicolás Peña <npm@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'core/fxge/win32/fx_win32_print.cpp')
-rw-r--r-- | core/fxge/win32/fx_win32_print.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/core/fxge/win32/fx_win32_print.cpp b/core/fxge/win32/fx_win32_print.cpp index e036a8c97d..8f7cbf5be0 100644 --- a/core/fxge/win32/fx_win32_print.cpp +++ b/core/fxge/win32/fx_win32_print.cpp @@ -337,8 +337,9 @@ CPSPrinterDriver::CPSPrinterDriver(HDC hDC, int pslevel, bool bCmykOutput) m_Width = ::GetDeviceCaps(m_hDC, HORZRES); m_Height = ::GetDeviceCaps(m_hDC, VERTRES); m_nBitsPerPixel = ::GetDeviceCaps(m_hDC, BITSPIXEL); - m_pPSOutput = pdfium::MakeUnique<CPSOutput>(m_hDC); - m_PSRenderer.Init(m_pPSOutput.get(), pslevel, m_Width, m_Height, bCmykOutput); + + m_PSRenderer.Init(pdfium::MakeRetain<CPSOutput>(m_hDC), pslevel, m_Width, + m_Height, bCmykOutput); HRGN hRgn = ::CreateRectRgn(0, 0, 1, 1); int ret = ::GetClipRgn(hDC, hRgn); if (ret == 1) { |