summaryrefslogtreecommitdiff
path: root/xfa/fxfa/cxfa_ffdocview.cpp
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2018-01-04 11:03:26 -0500
committerChromium commit bot <commit-bot@chromium.org>2018-01-04 16:46:22 +0000
commitd9dfb6cc16f689753e9b3f896fbda1aec791051a (patch)
tree8063ebecea18abc6989cac8b67b0d2fb03a4877a /xfa/fxfa/cxfa_ffdocview.cpp
parent8ee5207f4f792295badd21f90727e8c810e7dbdf (diff)
downloadpdfium-d9dfb6cc16f689753e9b3f896fbda1aec791051a.tar.xz
Merge CXFA_WidgetData into CXFA_WidgetAcc
This CL merges the CXFA_WidgetData class into the only subclass, CXFA_WidgetAcc. Code has been updated as needed. Change-Id: I3f5bc83b1422bcbe065276b16bfb91e656f5c174 Reviewed-on: https://pdfium-review.googlesource.com/22252 Reviewed-by: Ryan Harrison <rharrison@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
Diffstat (limited to 'xfa/fxfa/cxfa_ffdocview.cpp')
-rw-r--r--xfa/fxfa/cxfa_ffdocview.cpp14
1 files changed, 6 insertions, 8 deletions
diff --git a/xfa/fxfa/cxfa_ffdocview.cpp b/xfa/fxfa/cxfa_ffdocview.cpp
index 1160d55999..e5d2fe12dc 100644
--- a/xfa/fxfa/cxfa_ffdocview.cpp
+++ b/xfa/fxfa/cxfa_ffdocview.cpp
@@ -237,7 +237,7 @@ bool CXFA_FFDocView::ResetSingleWidgetAccData(CXFA_WidgetAcc* pWidgetAcc) {
return true;
}
-void CXFA_FFDocView::ResetWidgetData(CXFA_WidgetAcc* pWidgetAcc) {
+void CXFA_FFDocView::ResetWidgetAcc(CXFA_WidgetAcc* pWidgetAcc) {
m_bLayoutEvent = true;
bool bChanged = false;
CXFA_Node* pFormNode = nullptr;
@@ -445,7 +445,7 @@ int32_t CXFA_FFDocView::ExecEventActivityByDeepFirst(CXFA_Node* pFormNode,
if (eEventType == XFA_EVENT_IndexChange)
return XFA_EVENTERROR_NotExist;
- CXFA_WidgetAcc* pWidgetAcc = (CXFA_WidgetAcc*)pFormNode->GetWidgetData();
+ CXFA_WidgetAcc* pWidgetAcc = pFormNode->GetWidgetAcc();
if (!pWidgetAcc)
return XFA_EVENTERROR_NotExist;
@@ -470,7 +470,7 @@ int32_t CXFA_FFDocView::ExecEventActivityByDeepFirst(CXFA_Node* pFormNode,
}
}
}
- CXFA_WidgetAcc* pWidgetAcc = (CXFA_WidgetAcc*)pFormNode->GetWidgetData();
+ CXFA_WidgetAcc* pWidgetAcc = pFormNode->GetWidgetAcc();
if (!pWidgetAcc)
return iRet;
@@ -517,7 +517,7 @@ CXFA_WidgetAcc* CXFA_FFDocView::GetWidgetAccByName(
if (resolveNodeRS.dwFlags == XFA_ResolveNode_RSType_Nodes) {
CXFA_Node* pNode = resolveNodeRS.objects.front()->AsNode();
if (pNode)
- return static_cast<CXFA_WidgetAcc*>(pNode->GetWidgetData());
+ return pNode->GetWidgetAcc();
}
return nullptr;
}
@@ -573,8 +573,7 @@ bool CXFA_FFDocView::RunLayout() {
void CXFA_FFDocView::RunSubformIndexChange() {
for (CXFA_Node* pSubformNode : m_IndexChangedSubforms) {
- CXFA_WidgetAcc* pWidgetAcc =
- static_cast<CXFA_WidgetAcc*>(pSubformNode->GetWidgetData());
+ CXFA_WidgetAcc* pWidgetAcc = pSubformNode->GetWidgetAcc();
if (!pWidgetAcc)
continue;
@@ -712,8 +711,7 @@ void CXFA_FFDocView::RunBindItems() {
continue;
CXFA_Node* pWidgetNode = item->GetNodeItem(XFA_NODEITEM_Parent);
- CXFA_WidgetAcc* pAcc =
- static_cast<CXFA_WidgetAcc*>(pWidgetNode->GetWidgetData());
+ CXFA_WidgetAcc* pAcc = pWidgetNode->GetWidgetAcc();
if (!pAcc)
continue;