From 4f88617ad2a4d352af87b95c2f7293d12e7bd2c8 Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Wed, 3 Jan 2018 16:21:33 -0500 Subject: Fold CXFA_LineData into CXFA_Line This CL merges the CXFA_LineData wrapper into CXFA_Line. Change-Id: If5299797a615d2c0abb661e72a9e036e69f96385 Reviewed-on: https://pdfium-review.googlesource.com/22112 Reviewed-by: Ryan Harrison Commit-Queue: dsinclair --- xfa/fxfa/cxfa_ffline.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'xfa/fxfa/cxfa_ffline.cpp') diff --git a/xfa/fxfa/cxfa_ffline.cpp b/xfa/fxfa/cxfa_ffline.cpp index c1bcc26b27..7d3ce6a619 100644 --- a/xfa/fxfa/cxfa_ffline.cpp +++ b/xfa/fxfa/cxfa_ffline.cpp @@ -7,6 +7,7 @@ #include "xfa/fxfa/cxfa_ffline.h" #include "xfa/fxfa/parser/cxfa_edge.h" +#include "xfa/fxfa/parser/cxfa_line.h" #include "xfa/fxfa/parser/cxfa_value.h" #include "xfa/fxgraphics/cxfa_gecolor.h" #include "xfa/fxgraphics/cxfa_gepath.h" @@ -90,12 +91,12 @@ void CXFA_FFLine::RenderWidget(CXFA_Graphics* pGS, if (!value) return; - CXFA_LineData lineData = value->GetLineData(); + CXFA_Line* line = value->GetLine(); FX_ARGB lineColor = 0xFF000000; float fLineWidth = 1.0f; XFA_AttributeEnum iStrokeType = XFA_AttributeEnum::Unknown; XFA_AttributeEnum iCap = XFA_AttributeEnum::Unknown; - CXFA_Edge* edge = lineData.GetEdge(); + CXFA_Edge* edge = line->GetEdge(); if (edge) { if (!edge->IsVisible()) return; @@ -114,9 +115,9 @@ void CXFA_FFLine::RenderWidget(CXFA_Graphics* pGS, if (margin) XFA_RectWidthoutMargin(rtLine, margin); - GetRectFromHand(rtLine, lineData.GetHand(), fLineWidth); + GetRectFromHand(rtLine, line->GetHand(), fLineWidth); CXFA_GEPath linePath; - if (lineData.GetSlope() && rtLine.right() > 0.0f && rtLine.bottom() > 0.0f) + if (line->GetSlope() && rtLine.right() > 0.0f && rtLine.bottom() > 0.0f) linePath.AddLine(rtLine.TopRight(), rtLine.BottomLeft()); else linePath.AddLine(rtLine.TopLeft(), rtLine.BottomRight()); -- cgit v1.2.3