diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2018-01-08 12:28:27 -0500 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2018-01-08 17:58:37 +0000 |
commit | 2f265dbf12831dece93a6a932fd99e5737cd1afd (patch) | |
tree | b853bbf28556893ad6abb4a9e5702ebe256a8320 /xfa/fxfa/cxfa_fwltheme.cpp | |
parent | 5dc906eeda8cef7aff368e3c8efed37c0a5b3162 (diff) | |
download | pdfium-2f265dbf12831dece93a6a932fd99e5737cd1afd.tar.xz |
Move proxy methods from CXFA_WidgetAcc to CXFA_Node
This CL moves methods from WidgetAcc which just proxy to CXFA_Node.
Change-Id: Icf1006b4be3f91077de411ed1a571b1507117602
Reviewed-on: https://pdfium-review.googlesource.com/22391
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'xfa/fxfa/cxfa_fwltheme.cpp')
-rw-r--r-- | xfa/fxfa/cxfa_fwltheme.cpp | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/xfa/fxfa/cxfa_fwltheme.cpp b/xfa/fxfa/cxfa_fwltheme.cpp index f42c9ac022..ed54ab1a9d 100644 --- a/xfa/fxfa/cxfa_fwltheme.cpp +++ b/xfa/fxfa/cxfa_fwltheme.cpp @@ -134,8 +134,8 @@ void CXFA_FWLTheme::DrawText(CFWL_ThemeText* pParams) { m_pTextOut->SetStyles(pParams->m_dwTTOStyles); m_pTextOut->SetAlignment(pParams->m_iTTOAlign); m_pTextOut->SetFont(pAcc->GetFDEFont(pWidget->GetDoc())); - m_pTextOut->SetFontSize(pAcc->GetFontSize()); - m_pTextOut->SetTextColor(pAcc->GetTextColor()); + m_pTextOut->SetFontSize(pAcc->GetNode()->GetFontSize()); + m_pTextOut->SetTextColor(pAcc->GetNode()->GetTextColor()); CFX_Matrix mtPart = pParams->m_matrix; const CFX_Matrix* pMatrix = pGraphics->GetMatrix(); if (pMatrix) @@ -155,7 +155,7 @@ CFX_RectF CXFA_FWLTheme::GetUIMargin(CFWL_ThemePart* pThemePart) const { CXFA_LayoutItem* pItem = pWidget; CXFA_WidgetAcc* pWidgetAcc = pWidget->GetDataAcc(); rect = pWidgetAcc->GetUIMargin(); - CXFA_Para* para = pWidgetAcc->GetPara(); + CXFA_Para* para = pWidgetAcc->GetNode()->GetPara(); if (para) { rect.left += para->GetMarginLeft(); if (pWidgetAcc->IsMultiLine()) @@ -183,7 +183,7 @@ float CXFA_FWLTheme::GetCYBorderSize() const { float CXFA_FWLTheme::GetFontSize(CFWL_ThemePart* pThemePart) const { if (CXFA_FFWidget* pWidget = XFA_ThemeGetOuterWidget(pThemePart->m_pWidget)) - return pWidget->GetDataAcc()->GetFontSize(); + return pWidget->GetDataAcc()->GetNode()->GetFontSize(); return FWLTHEME_CAPACITY_FontSize; } @@ -196,7 +196,7 @@ RetainPtr<CFGAS_GEFont> CXFA_FWLTheme::GetFont( float CXFA_FWLTheme::GetLineHeight(CFWL_ThemePart* pThemePart) const { if (CXFA_FFWidget* pWidget = XFA_ThemeGetOuterWidget(pThemePart->m_pWidget)) - return pWidget->GetDataAcc()->GetLineHeight(); + return pWidget->GetDataAcc()->GetNode()->GetLineHeight(); return kLineHeight; } @@ -206,15 +206,14 @@ float CXFA_FWLTheme::GetScrollBarWidth() const { FX_COLORREF CXFA_FWLTheme::GetTextColor(CFWL_ThemePart* pThemePart) const { if (CXFA_FFWidget* pWidget = XFA_ThemeGetOuterWidget(pThemePart->m_pWidget)) - return pWidget->GetDataAcc()->GetTextColor(); + return pWidget->GetDataAcc()->GetNode()->GetTextColor(); return FWLTHEME_CAPACITY_TextColor; } CFX_SizeF CXFA_FWLTheme::GetSpaceAboveBelow(CFWL_ThemePart* pThemePart) const { CFX_SizeF sizeAboveBelow; if (CXFA_FFWidget* pWidget = XFA_ThemeGetOuterWidget(pThemePart->m_pWidget)) { - CXFA_WidgetAcc* pWidgetAcc = pWidget->GetDataAcc(); - CXFA_Para* para = pWidgetAcc->GetPara(); + CXFA_Para* para = pWidget->GetDataAcc()->GetNode()->GetPara(); if (para) { sizeAboveBelow.width = para->GetSpaceAbove(); sizeAboveBelow.height = para->GetSpaceBelow(); @@ -243,8 +242,8 @@ void CXFA_FWLTheme::CalcTextRect(CFWL_ThemeText* pParams, CFX_RectF& rect) { CXFA_WidgetAcc* pAcc = pWidget->GetDataAcc(); m_pTextOut->SetFont(pAcc->GetFDEFont(pWidget->GetDoc())); - m_pTextOut->SetFontSize(pAcc->GetFontSize()); - m_pTextOut->SetTextColor(pAcc->GetTextColor()); + m_pTextOut->SetFontSize(pAcc->GetNode()->GetFontSize()); + m_pTextOut->SetTextColor(pAcc->GetNode()->GetTextColor()); if (!pParams) return; |