summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authordan sinclair <dsinclair@chromium.org>2017-05-11 09:57:27 -0400
committerChromium commit bot <commit-bot@chromium.org>2017-05-11 20:19:30 +0000
commite6324fa7137fa224daa397464293e0c74e1c68ce (patch)
tree7e5a8246bfad7675f280857e53c1f7d745c6f469 /core
parentcb377bec7023723b23a015921ef781cb355b3c92 (diff)
downloadpdfium-e6324fa7137fa224daa397464293e0c74e1c68ce.tar.xz
Remove unused GetPlatformSurface and GetDC methods
The times we need the DC we call ::GetDC to retrieve it from the platform. These methods are unused. Change-Id: If83aa9b37ae2231d8029db6f2e6d8d17f1825611 Reviewed-on: https://pdfium-review.googlesource.com/5350 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'core')
-rw-r--r--core/fxge/cfx_windowsdevice.h2
-rw-r--r--core/fxge/ifx_renderdevicedriver.cpp4
-rw-r--r--core/fxge/ifx_renderdevicedriver.h1
-rw-r--r--core/fxge/win32/cfx_windowsdib.h1
-rw-r--r--core/fxge/win32/fx_win32_device.cpp9
-rw-r--r--core/fxge/win32/fx_win32_print.cpp4
-rw-r--r--core/fxge/win32/win32_int.h2
7 files changed, 0 insertions, 23 deletions
diff --git a/core/fxge/cfx_windowsdevice.h b/core/fxge/cfx_windowsdevice.h
index 6240d84219..2d17cb7dd8 100644
--- a/core/fxge/cfx_windowsdevice.h
+++ b/core/fxge/cfx_windowsdevice.h
@@ -33,8 +33,6 @@ class CFX_WindowsDevice : public CFX_RenderDevice {
explicit CFX_WindowsDevice(HDC hDC);
~CFX_WindowsDevice() override;
-
- HDC GetDC() const;
};
#endif // _WIN32
diff --git a/core/fxge/ifx_renderdevicedriver.cpp b/core/fxge/ifx_renderdevicedriver.cpp
index fae86cbfc6..9b94e883f2 100644
--- a/core/fxge/ifx_renderdevicedriver.cpp
+++ b/core/fxge/ifx_renderdevicedriver.cpp
@@ -73,10 +73,6 @@ bool IFX_RenderDeviceDriver::DrawDeviceText(int nChars,
return false;
}
-void* IFX_RenderDeviceDriver::GetPlatformSurface() const {
- return nullptr;
-}
-
int IFX_RenderDeviceDriver::GetDriverType() const {
return 0;
}
diff --git a/core/fxge/ifx_renderdevicedriver.h b/core/fxge/ifx_renderdevicedriver.h
index 97f35b641b..f4df846011 100644
--- a/core/fxge/ifx_renderdevicedriver.h
+++ b/core/fxge/ifx_renderdevicedriver.h
@@ -94,7 +94,6 @@ class IFX_RenderDeviceDriver {
const CFX_Matrix* pObject2Device,
float font_size,
uint32_t color);
- virtual void* GetPlatformSurface() const;
virtual int GetDriverType() const;
virtual void ClearDriver();
virtual bool DrawShading(const CPDF_ShadingPattern* pPattern,
diff --git a/core/fxge/win32/cfx_windowsdib.h b/core/fxge/win32/cfx_windowsdib.h
index e59e9d60a4..3ecbb5835d 100644
--- a/core/fxge/win32/cfx_windowsdib.h
+++ b/core/fxge/win32/cfx_windowsdib.h
@@ -43,7 +43,6 @@ class CFX_WindowsDIB : public CFX_DIBitmap {
static CFX_RetainPtr<CFX_DIBitmap> LoadFromFile(const char* filename);
static CFX_RetainPtr<CFX_DIBitmap> LoadDIBitmap(WINDIB_Open_Args_ args);
- HDC GetDC() const { return m_hMemDC; }
HBITMAP GetWindowsBitmap() const { return m_hBitmap; }
void LoadFromDevice(HDC hDC, int left, int top);
diff --git a/core/fxge/win32/fx_win32_device.cpp b/core/fxge/win32/fx_win32_device.cpp
index 6e960f95b4..43d53e1bb0 100644
--- a/core/fxge/win32/fx_win32_device.cpp
+++ b/core/fxge/win32/fx_win32_device.cpp
@@ -929,10 +929,6 @@ bool CGdiDeviceDriver::GetClipBox(FX_RECT* pRect) {
return !!(::GetClipBox(m_hDC, (RECT*)pRect));
}
-void* CGdiDeviceDriver::GetPlatformSurface() const {
- return (void*)m_hDC;
-}
-
void CGdiDeviceDriver::DrawLine(float x1, float y1, float x2, float y2) {
if (!m_bMetafileDCType) { // EMF drawing is not bound to the DC.
int startOutOfBoundsFlag = (x1 < 0) | ((x1 > m_Width) << 1) |
@@ -1368,11 +1364,6 @@ CFX_WindowsDevice::CFX_WindowsDevice(HDC hDC) {
CFX_WindowsDevice::~CFX_WindowsDevice() {}
-HDC CFX_WindowsDevice::GetDC() const {
- IFX_RenderDeviceDriver* pRDD = GetDeviceDriver();
- return pRDD ? reinterpret_cast<HDC>(pRDD->GetPlatformSurface()) : nullptr;
-}
-
// static
IFX_RenderDeviceDriver* CFX_WindowsDevice::CreateDriver(HDC hDC) {
int device_type = ::GetDeviceCaps(hDC, TECHNOLOGY);
diff --git a/core/fxge/win32/fx_win32_print.cpp b/core/fxge/win32/fx_win32_print.cpp
index 86636b5bfa..f060c04127 100644
--- a/core/fxge/win32/fx_win32_print.cpp
+++ b/core/fxge/win32/fx_win32_print.cpp
@@ -491,7 +491,3 @@ bool CPSPrinterDriver::DrawDeviceText(int nChars,
return m_PSRenderer.DrawText(nChars, pCharPos, pFont, pObject2Device,
font_size, color);
}
-
-void* CPSPrinterDriver::GetPlatformSurface() const {
- return m_hDC;
-}
diff --git a/core/fxge/win32/win32_int.h b/core/fxge/win32/win32_int.h
index a5fc853de5..2f69c0ea57 100644
--- a/core/fxge/win32/win32_int.h
+++ b/core/fxge/win32/win32_int.h
@@ -156,7 +156,6 @@ class CGdiDeviceDriver : public IFX_RenderDeviceDriver {
uint32_t color,
int blend_type) override;
bool GetClipBox(FX_RECT* pRect) override;
- void* GetPlatformSurface() const override;
void DrawLine(float x1, float y1, float x2, float y2);
@@ -322,7 +321,6 @@ class CPSPrinterDriver : public IFX_RenderDeviceDriver {
const CFX_Matrix* pObject2Device,
float font_size,
uint32_t color) override;
- void* GetPlatformSurface() const override;
HDC m_hDC;
bool m_bCmykOutput;