summaryrefslogtreecommitdiff
path: root/xfa/fde/fde_render.cpp
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2017-03-02 12:21:15 -0800
committerChromium commit bot <commit-bot@chromium.org>2017-03-02 21:01:30 +0000
commitc803cbcad51355ffa38dce0851a51dfdcf279645 (patch)
tree82fa82015ec801285231cf507ed97bdea5fc7e08 /xfa/fde/fde_render.cpp
parentc3f74e91b2f019c3035395f5605cb98409502385 (diff)
downloadpdfium-c803cbcad51355ffa38dce0851a51dfdcf279645.tar.xz
Use std::deque for CFX_MassArrayTemplate<FDE_TEXTEDITPIECE>
Change-Id: I1080eefb4e47d7bc86fb3384fd7479a1fd49b203 Reviewed-on: https://pdfium-review.googlesource.com/2898 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'xfa/fde/fde_render.cpp')
-rw-r--r--xfa/fde/fde_render.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/xfa/fde/fde_render.cpp b/xfa/fde/fde_render.cpp
index c0fb926c36..b6a8f7edd0 100644
--- a/xfa/fde/fde_render.cpp
+++ b/xfa/fde/fde_render.cpp
@@ -61,7 +61,6 @@ FDE_RENDERSTATUS CFDE_RenderContext::DoRender(IFX_Pause* pPause) {
rm.TransformRect(rtDocClip);
IFDE_VisualSet* pVisualSet;
FDE_TEXTEDITPIECE* pPiece;
- CFX_RectF rtObj;
int32_t iCount = 0;
while (true) {
pPiece = m_pIterator->GetNext(pVisualSet);
@@ -69,9 +68,7 @@ FDE_RENDERSTATUS CFDE_RenderContext::DoRender(IFX_Pause* pPause) {
eStatus = FDE_RENDERSTATUS_Done;
break;
}
- rtObj.Empty();
- pVisualSet->GetRect(pPiece, rtObj);
- if (!rtDocClip.IntersectWith(rtObj))
+ if (!rtDocClip.IntersectWith(pVisualSet->GetRect(*pPiece)))
continue;
switch (pVisualSet->GetType()) {
@@ -111,7 +108,7 @@ void CFDE_RenderContext::RenderText(IFDE_TextSet* pTextSet,
if (!pFont)
return;
- int32_t iCount = pTextSet->GetDisplayPos(pText, nullptr, false);
+ int32_t iCount = pTextSet->GetDisplayPos(*pText, nullptr, false);
if (iCount < 1)
return;
@@ -121,7 +118,7 @@ void CFDE_RenderContext::RenderText(IFDE_TextSet* pTextSet,
if (m_CharPos.size() < static_cast<size_t>(iCount))
m_CharPos.resize(iCount, FXTEXT_CHARPOS());
- iCount = pTextSet->GetDisplayPos(pText, m_CharPos.data(), false);
+ iCount = pTextSet->GetDisplayPos(*pText, m_CharPos.data(), false);
FX_FLOAT fFontSize = pTextSet->GetFontSize();
FX_ARGB dwColor = pTextSet->GetFontColor();
m_pBrush->SetColor(dwColor);