summaryrefslogtreecommitdiff
path: root/core/fpdfdoc/doc_form.cpp
diff options
context:
space:
mode:
authortsepez <tsepez@chromium.org>2016-06-08 14:17:24 -0700
committerCommit bot <commit-bot@chromium.org>2016-06-08 14:17:24 -0700
commit6aac8a822ef227b80173f23ea3169b28a6712bba (patch)
treecbc58444ac269f977e935740aee2dafab9c9c6ee /core/fpdfdoc/doc_form.cpp
parentc1835615f386d8e6e30df89b6517ebf605335a0e (diff)
downloadpdfium-6aac8a822ef227b80173f23ea3169b28a6712bba.tar.xz
Remove even more const casting from core.
Make the return types/arguments match reality. Review-Url: https://codereview.chromium.org/2053483002
Diffstat (limited to 'core/fpdfdoc/doc_form.cpp')
-rw-r--r--core/fpdfdoc/doc_form.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/core/fpdfdoc/doc_form.cpp b/core/fpdfdoc/doc_form.cpp
index 25a9f0b72d..b2c5d8cdf7 100644
--- a/core/fpdfdoc/doc_form.cpp
+++ b/core/fpdfdoc/doc_form.cpp
@@ -989,16 +989,15 @@ CPDF_FormField* CPDF_InterForm::AddTerminalField(CPDF_Dictionary* pFieldDict) {
}
return pField;
}
-CPDF_FormControl* CPDF_InterForm::AddControl(const CPDF_FormField* pField,
+CPDF_FormControl* CPDF_InterForm::AddControl(CPDF_FormField* pField,
CPDF_Dictionary* pWidgetDict) {
const auto it = m_ControlMap.find(pWidgetDict);
if (it != m_ControlMap.end())
return it->second;
- CPDF_FormControl* pControl =
- new CPDF_FormControl((CPDF_FormField*)pField, pWidgetDict);
+ CPDF_FormControl* pControl = new CPDF_FormControl(pField, pWidgetDict);
m_ControlMap[pWidgetDict] = pControl;
- ((CPDF_FormField*)pField)->m_ControlList.Add(pControl);
+ pField->m_ControlList.Add(pControl);
return pControl;
}