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

Unified Diff: core/src/fpdfdoc/doc_formfield.cpp

Issue 1655423002: Merge to XFA: Kill CFX_ByteArray in master. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: Still wonked. Created 4 years, 11 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/src/fpdfdoc/doc_formcontrol.cpp ('k') | core/src/fpdfdoc/doc_utils.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/src/fpdfdoc/doc_formfield.cpp
diff --git a/core/src/fpdfdoc/doc_formfield.cpp b/core/src/fpdfdoc/doc_formfield.cpp
index 39af0c94c70953db5b16e1d64313687beec81857..31557b490dcd3782cc9f760bbc514072baad69cc 100644
--- a/core/src/fpdfdoc/doc_formfield.cpp
+++ b/core/src/fpdfdoc/doc_formfield.cpp
@@ -102,10 +102,6 @@ FX_BOOL CPDF_FormField::ResetField(FX_BOOL bNotify) {
switch (m_Type) {
case CPDF_FormField::CheckBox:
case CPDF_FormField::RadioButton: {
- CFX_ByteArray statusArray;
- if (bNotify && m_pForm->m_pFormNotify) {
- SaveCheckedFieldStatus(this, statusArray);
- }
int iCount = CountControls();
if (iCount) {
if (PDF_FormField_IsUnison(this)) {
@@ -121,7 +117,7 @@ FX_BOOL CPDF_FormField::ResetField(FX_BOOL bNotify) {
}
}
if (bNotify && m_pForm->m_pFormNotify) {
- m_pForm->m_pFormNotify->AfterCheckedStatusChange(this, statusArray);
+ m_pForm->m_pFormNotify->AfterCheckedStatusChange(this);
}
} break;
case CPDF_FormField::ComboBox: {
@@ -805,8 +801,8 @@ FX_BOOL CPDF_FormField::ClearOptions(FX_BOOL bNotify) {
}
#endif // PDF_ENABLE_XFA
FX_BOOL CPDF_FormField::CheckControl(int iControlIndex,
- FX_BOOL bChecked,
- FX_BOOL bNotify) {
+ bool bChecked,
+ bool bNotify) {
ASSERT(GetType() == CheckBox || GetType() == RadioButton);
CPDF_FormControl* pControl = GetControl(iControlIndex);
if (!pControl) {
@@ -815,10 +811,6 @@ FX_BOOL CPDF_FormField::CheckControl(int iControlIndex,
if (!bChecked && pControl->IsChecked() == bChecked) {
return FALSE;
}
- CFX_ByteArray statusArray;
- if (bNotify && m_pForm->m_pFormNotify) {
- SaveCheckedFieldStatus(this, statusArray);
- }
CFX_WideString csWExport = pControl->GetExportValue();
CFX_ByteString csBExport = PDF_EncodeText(csWExport);
int iCount = CountControls();
@@ -864,7 +856,7 @@ FX_BOOL CPDF_FormField::CheckControl(int iControlIndex,
m_pDict->SetAtName("V", csIndex);
}
if (bNotify && m_pForm->m_pFormNotify) {
- m_pForm->m_pFormNotify->AfterCheckedStatusChange(this, statusArray);
+ m_pForm->m_pFormNotify->AfterCheckedStatusChange(this);
}
m_pForm->m_bUpdated = TRUE;
return TRUE;
@@ -892,10 +884,6 @@ FX_BOOL CPDF_FormField::SetCheckValue(const CFX_WideString& value,
FX_BOOL bDefault,
FX_BOOL bNotify) {
ASSERT(GetType() == CheckBox || GetType() == RadioButton);
- CFX_ByteArray statusArray;
- if (bNotify && m_pForm->m_pFormNotify) {
- SaveCheckedFieldStatus(this, statusArray);
- }
int iCount = CountControls();
for (int i = 0; i < iCount; i++) {
CPDF_FormControl* pControl = GetControl(i);
@@ -914,7 +902,7 @@ FX_BOOL CPDF_FormField::SetCheckValue(const CFX_WideString& value,
}
}
if (bNotify && m_pForm->m_pFormNotify) {
- m_pForm->m_pFormNotify->AfterCheckedStatusChange(this, statusArray);
+ m_pForm->m_pFormNotify->AfterCheckedStatusChange(this);
}
m_pForm->m_bUpdated = TRUE;
return TRUE;
« no previous file with comments | « core/src/fpdfdoc/doc_formcontrol.cpp ('k') | core/src/fpdfdoc/doc_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698