Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1239)

Unified Diff: core/fpdfdoc/doc_form.cpp

Issue 2049003003: Add some consts and remove more casts in core/ (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/fpdfdoc/ctypeset.cpp ('k') | core/fpdfdoc/doc_formfield.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fpdfdoc/doc_form.cpp
diff --git a/core/fpdfdoc/doc_form.cpp b/core/fpdfdoc/doc_form.cpp
index 7ecf35de37155ec8763499b0a4bf035428f13206..25a9f0b72d32112d0e775868379d3b9a6d075650 100644
--- a/core/fpdfdoc/doc_form.cpp
+++ b/core/fpdfdoc/doc_form.cpp
@@ -620,8 +620,7 @@ FX_BOOL CPDF_InterForm::ValidateFieldName(CFX_WideString& csNewFieldName,
FX_BOOL CPDF_InterForm::ValidateFieldName(const CPDF_FormField* pField,
CFX_WideString& csNewFieldName) {
return pField && !csNewFieldName.IsEmpty() &&
- ValidateFieldName(csNewFieldName,
- ((CPDF_FormField*)pField)->GetFieldType(), pField,
+ ValidateFieldName(csNewFieldName, pField->GetFieldType(), pField,
nullptr);
}
FX_BOOL CPDF_InterForm::ValidateFieldName(const CPDF_FormControl* pControl,
@@ -629,7 +628,7 @@ FX_BOOL CPDF_InterForm::ValidateFieldName(const CPDF_FormControl* pControl,
if (!pControl || csNewFieldName.IsEmpty()) {
return FALSE;
}
- CPDF_FormField* pField = ((CPDF_FormControl*)pControl)->GetField();
+ CPDF_FormField* pField = pControl->GetField();
return ValidateFieldName(csNewFieldName, pField->GetFieldType(), pField,
pControl);
}
« no previous file with comments | « core/fpdfdoc/ctypeset.cpp ('k') | core/fpdfdoc/doc_formfield.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698