diff options
author | tsepez <tsepez@chromium.org> | 2017-01-24 06:12:34 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2017-01-24 06:12:34 -0800 |
commit | 3d328767f9c0c04b62173aac03c35aab3fb87ffe (patch) | |
tree | 18a1a71ee987831e427b0dd62d26745861258a22 /xfa/fde/tto/fde_textout.cpp | |
parent | e73fea598f088151213fb11100798c615543ca2f (diff) | |
download | pdfium-3d328767f9c0c04b62173aac03c35aab3fb87ffe.tar.xz |
Use std::vector for CFX_RectF arrays
Review-Url: https://codereview.chromium.org/2653743002
Diffstat (limited to 'xfa/fde/tto/fde_textout.cpp')
-rw-r--r-- | xfa/fde/tto/fde_textout.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/xfa/fde/tto/fde_textout.cpp b/xfa/fde/tto/fde_textout.cpp index 4d207fb734..ca5aa566e1 100644 --- a/xfa/fde/tto/fde_textout.cpp +++ b/xfa/fde/tto/fde_textout.cpp @@ -814,8 +814,8 @@ int32_t CFDE_TextOut::GetDisplayPos(FDE_TTOPIECE* pPiece) { int32_t CFDE_TextOut::GetCharRects(const FDE_TTOPIECE* pPiece) { FX_TXTRUN tr = ToTextRun(pPiece); - m_rectArray.RemoveAll(); - return m_pTxtBreak->GetCharRects(&tr, m_rectArray); + m_rectArray.clear(); + return m_pTxtBreak->GetCharRects(&tr, &m_rectArray); } FX_TXTRUN CFDE_TextOut::ToTextRun(const FDE_TTOPIECE* pPiece) { @@ -886,7 +886,7 @@ void CFDE_TextOut::DrawLine(const FDE_TTOPIECE* pPiece, CFDE_Pen*& pPen) { int32_t iCharIndex = m_hotKeys.GetAt(i); if (iCharIndex >= pPiece->iStartChar && iCharIndex < pPiece->iStartChar + pPiece->iChars) { - CFX_RectF rect = m_rectArray.GetAt(iCharIndex - pPiece->iStartChar); + CFX_RectF rect = m_rectArray[iCharIndex - pPiece->iStartChar]; if (bVertical) { pt1.x = rect.left; pt1.y = rect.top; |