summaryrefslogtreecommitdiff
path: root/core/fxge/win32/fx_win32_device.cpp
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2018-04-25 18:01:52 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-04-25 18:01:52 +0000
commit537f4c7b592a6981f9686297496cb23b461dfd5e (patch)
treeaf3ba90c5a64eaa24e252484c3484f9b8ed94d9b /core/fxge/win32/fx_win32_device.cpp
parent306b9a87090ba4c4cc8453ef04f230620e224fe0 (diff)
downloadpdfium-537f4c7b592a6981f9686297496cb23b461dfd5e.tar.xz
Use WindowsPrintMode in more places in place of ints.
Move WindowsPrintMode assertion into CPSPrinterDriver. Change-Id: I570076b43751e052c5396e89a6674b83a4ad1a1e Reviewed-on: https://pdfium-review.googlesource.com/31298 Reviewed-by: Rebekah Potter <rbpotter@chromium.org> Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
Diffstat (limited to 'core/fxge/win32/fx_win32_device.cpp')
-rw-r--r--core/fxge/win32/fx_win32_device.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/core/fxge/win32/fx_win32_device.cpp b/core/fxge/win32/fx_win32_device.cpp
index f5b062ba61..ed03101ecd 100644
--- a/core/fxge/win32/fx_win32_device.cpp
+++ b/core/fxge/win32/fx_win32_device.cpp
@@ -671,7 +671,7 @@ bool CFX_Win32FontInfo::GetFontCharset(void* hFont, int* charset) {
} // namespace
-int g_pdfium_print_mode = WindowsPrintMode::kModeEmf;
+WindowsPrintMode g_pdfium_print_mode = WindowsPrintMode::kModeEmf;
std::unique_ptr<SystemFontInfoIface> SystemFontInfoIface::CreateDefault(
const char** pUnused) {
@@ -1361,8 +1361,5 @@ RenderDeviceDriverIface* CFX_WindowsRenderDevice::CreateDriver(HDC hDC) {
if (g_pdfium_print_mode == WindowsPrintMode::kModeTextOnly)
return new CTextOnlyPrinterDriver(hDC);
- // Should be PostScript
- ASSERT(g_pdfium_print_mode == WindowsPrintMode::kModePostScript2 ||
- g_pdfium_print_mode == WindowsPrintMode::kModePostScript3);
return new CPSPrinterDriver(hDC, g_pdfium_print_mode, false);
}