summaryrefslogtreecommitdiff
path: root/core/fxge/win32/cpsoutput.h
diff options
context:
space:
mode:
authordan sinclair <dsinclair@chromium.org>2017-05-12 21:22:08 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-05-15 15:40:43 +0000
commitd2afac1e9200478997e308eecc582a073185d7ab (patch)
tree1ec1a2c69168cb2ab3f1418fae0e9f1c754cebdb /core/fxge/win32/cpsoutput.h
parent017ebba6940e0fe5ff39122c033600f88f24539a (diff)
downloadpdfium-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/cpsoutput.h')
-rw-r--r--core/fxge/win32/cpsoutput.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/core/fxge/win32/cpsoutput.h b/core/fxge/win32/cpsoutput.h
index 1a4709b36b..42ad109a80 100644
--- a/core/fxge/win32/cpsoutput.h
+++ b/core/fxge/win32/cpsoutput.h
@@ -9,17 +9,19 @@
#include <windows.h>
+#include "core/fxcrt/fx_stream.h"
#include "core/fxcrt/fx_system.h"
-class CPSOutput {
+class CPSOutput : public IFX_WriteStream {
public:
explicit CPSOutput(HDC hDC);
- ~CPSOutput();
+ ~CPSOutput() override;
- // IFX_PSOutput
- void Release();
- void OutputPS(const char* str, int len);
+ // IFX_Writestream
+ bool WriteBlock(const void* str, size_t len) override;
+ bool WriteString(const CFX_ByteStringC& str) override;
+ private:
HDC m_hDC;
};