summaryrefslogtreecommitdiff
path: root/fpdfsdk/formfiller/cffl_radiobutton.cpp
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2018-08-16 20:53:58 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-08-16 20:53:58 +0000
commitb2e6b4c44a38ea2ca9e021df31cd27eb67a45e35 (patch)
tree8e9392c73c3905d38d9e9e636adf8df9c7af072e /fpdfsdk/formfiller/cffl_radiobutton.cpp
parentaa987a9a895d42749c0f5e4092618fe7ded6667e (diff)
downloadpdfium-b2e6b4c44a38ea2ca9e021df31cd27eb67a45e35.tar.xz
Replace optional bool bNotify with enum type.
Adds clarity to the call sites. Change-Id: Id4deed9adda2ad79f0847d618792429044d4f7d6 Reviewed-on: https://pdfium-review.googlesource.com/40351 Reviewed-by: Lei Zhang <thestig@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'fpdfsdk/formfiller/cffl_radiobutton.cpp')
-rw-r--r--fpdfsdk/formfiller/cffl_radiobutton.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/fpdfsdk/formfiller/cffl_radiobutton.cpp b/fpdfsdk/formfiller/cffl_radiobutton.cpp
index 73ac44de46..8105b0cdea 100644
--- a/fpdfsdk/formfiller/cffl_radiobutton.cpp
+++ b/fpdfsdk/formfiller/cffl_radiobutton.cpp
@@ -91,26 +91,25 @@ void CFFL_RadioButton::SaveData(CPDFSDK_PageView* pPageView) {
return;
bool bNewChecked = pWnd->IsChecked();
-
if (bNewChecked) {
CPDF_FormField* pField = m_pWidget->GetFormField();
for (int32_t i = 0, sz = pField->CountControls(); i < sz; i++) {
if (CPDF_FormControl* pCtrl = pField->GetControl(i)) {
- if (pCtrl->IsChecked()) {
+ if (pCtrl->IsChecked())
break;
- }
}
}
}
CPDFSDK_Widget::ObservedPtr observed_widget(m_pWidget.Get());
CFFL_RadioButton::ObservedPtr observed_this(this);
-
- m_pWidget->SetCheck(bNewChecked, false);
+ m_pWidget->SetCheck(bNewChecked, NotificationOption::kDoNotNotify);
if (!observed_widget)
return;
+
m_pWidget->UpdateField();
if (!observed_widget || !observed_this)
return;
+
SetChangeMark();
}