From 7ffb59f7f540a67fb808c1e5a2a7edfacf125e3a Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Thu, 10 Aug 2017 10:16:06 -0400 Subject: Remove CFDE_Path This CL removes CFDE_Path. There is only one method, AddLine which is required, the rest can be removed. That method is moved to CFX_PathData which is what CFDE_Path is appending to anyway. Change-Id: If50af8cf856a9f7379791fe1999174db5fd13e38 Reviewed-on: https://pdfium-review.googlesource.com/10454 Reviewed-by: Henrique Nakashima Reviewed-by: Tom Sepez Commit-Queue: dsinclair --- xfa/fde/cfde_textout.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'xfa/fde/cfde_textout.cpp') diff --git a/xfa/fde/cfde_textout.cpp b/xfa/fde/cfde_textout.cpp index 202074bdc4..e796bdcdb3 100644 --- a/xfa/fde/cfde_textout.cpp +++ b/xfa/fde/cfde_textout.cpp @@ -11,9 +11,9 @@ #include "core/fxcrt/fx_coordinates.h" #include "core/fxcrt/fx_system.h" +#include "core/fxge/cfx_pathdata.h" #include "third_party/base/ptr_util.h" #include "third_party/base/stl_util.h" -#include "xfa/fde/cfde_path.h" #include "xfa/fde/cfde_renderdevice.h" #include "xfa/fgas/layout/cfx_txtbreak.h" @@ -704,7 +704,7 @@ void CFDE_TextOut::DrawLine(const FDE_TTOPIECE* pPiece, FX_ARGB color) { if (!bUnderLine && !bStrikeOut && !bHotKey) return; - auto pPath = pdfium::MakeUnique(); + CFX_PathData path; int32_t iLineCount = 0; CFX_RectF rtText = pPiece->rtPiece; CFX_PointF pt1, pt2; @@ -713,7 +713,7 @@ void CFDE_TextOut::DrawLine(const FDE_TTOPIECE* pPiece, FX_ARGB color) { pt1.y = rtText.bottom(); pt2.x = rtText.right(); pt2.y = rtText.bottom(); - pPath->AddLine(pt1, pt2); + path.AppendLine(pt1, pt2); iLineCount++; } if (bStrikeOut) { @@ -721,7 +721,7 @@ void CFDE_TextOut::DrawLine(const FDE_TTOPIECE* pPiece, FX_ARGB color) { pt1.y = rtText.bottom() - rtText.height * 2.0f / 5.0f; pt2.x = rtText.right(); pt2.y = pt1.y; - pPath->AddLine(pt1, pt2); + path.AppendLine(pt1, pt2); iLineCount++; } if (bHotKey) { @@ -734,14 +734,14 @@ void CFDE_TextOut::DrawLine(const FDE_TTOPIECE* pPiece, FX_ARGB color) { pt1.y = rect.bottom(); pt2.x = rect.right(); pt2.y = rect.bottom(); - pPath->AddLine(pt1, pt2); + path.AppendLine(pt1, pt2); iLineCount++; } } } } if (iLineCount > 0) - m_pRenderDevice->DrawPath(color, 1, pPath.get(), &m_Matrix); + m_pRenderDevice->DrawPath(color, 1, path, &m_Matrix); } CFDE_TTOLine::CFDE_TTOLine() : m_bNewReload(false) {} -- cgit v1.2.3