diff options
author | dsinclair <dsinclair@chromium.org> | 2016-06-06 12:03:31 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-06-06 12:03:32 -0700 |
commit | fe433f15d60f92ccde7a928160c2e7cc77dcb8bf (patch) | |
tree | 6b3e8362ba26166c29441b2fc32817fe7d93f4c7 /xfa/fde/fde_render.cpp | |
parent | 5a5f251ce8646ec421aa9e35d8bbca71a984770a (diff) | |
download | pdfium-fe433f15d60f92ccde7a928160c2e7cc77dcb8bf.tar.xz |
Remove FDE_HDEVICESTATE.
The value returned is always NULL and when passed as a param is never used.
Review-Url: https://codereview.chromium.org/2044623002
Diffstat (limited to 'xfa/fde/fde_render.cpp')
-rw-r--r-- | xfa/fde/fde_render.cpp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/xfa/fde/fde_render.cpp b/xfa/fde/fde_render.cpp index 283cd80ffb..57ad5bff72 100644 --- a/xfa/fde/fde_render.cpp +++ b/xfa/fde/fde_render.cpp @@ -134,17 +134,15 @@ void CFDE_RenderContext::RenderText(IFDE_TextSet* pTextSet, FX_FLOAT fFontSize = pTextSet->GetFontSize(hText); FX_ARGB dwColor = pTextSet->GetFontColor(hText); m_pBrush->SetColor(dwColor); - FDE_HDEVICESTATE hState; - FX_BOOL bClip = ApplyClip(pTextSet, hText, hState); + FX_BOOL bClip = ApplyClip(pTextSet, hText); m_pRenderDevice->DrawString(m_pBrush.get(), pFont, m_pCharPos, iCount, fFontSize, &m_Transform); if (bClip) - RestoreClip(hState); + RestoreClip(); } FX_BOOL CFDE_RenderContext::ApplyClip(IFDE_VisualSet* pVisualSet, - FDE_HVISUALOBJ hObj, - FDE_HDEVICESTATE& hState) { + FDE_HVISUALOBJ hObj) { CFX_RectF rtClip; if (!pVisualSet->GetClip(hObj, rtClip)) return FALSE; @@ -155,10 +153,10 @@ FX_BOOL CFDE_RenderContext::ApplyClip(IFDE_VisualSet* pVisualSet, m_Transform.TransformRect(rtClip); const CFX_RectF& rtDevClip = m_pRenderDevice->GetClipRect(); rtClip.Intersect(rtDevClip); - hState = m_pRenderDevice->SaveState(); + m_pRenderDevice->SaveState(); return m_pRenderDevice->SetClipRect(rtClip); } -void CFDE_RenderContext::RestoreClip(FDE_HDEVICESTATE hState) { - m_pRenderDevice->RestoreState(hState); +void CFDE_RenderContext::RestoreClip() { + m_pRenderDevice->RestoreState(); } |