diff options
author | Wei Li <weili@chromium.org> | 2016-03-15 10:58:40 -0700 |
---|---|---|
committer | Wei Li <weili@chromium.org> | 2016-03-15 10:58:40 -0700 |
commit | e40764862208b8cb76f507c489b01e3795fd93bd (patch) | |
tree | ea4c86bd75d17f91217df09747896a38e14934db /fpdfsdk/fsdk_baseform.cpp | |
parent | 3cc180234c14639d408003c8180ba2963f0ea665 (diff) | |
download | pdfium-e40764862208b8cb76f507c489b01e3795fd93bd.tar.xz |
Modify xfa code to avoid c4800 warnings
BUG=pdfium:29
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1800793002 .
Diffstat (limited to 'fpdfsdk/fsdk_baseform.cpp')
-rw-r--r-- | fpdfsdk/fsdk_baseform.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/fpdfsdk/fsdk_baseform.cpp b/fpdfsdk/fsdk_baseform.cpp index 141e1f5f82..6a01813494 100644 --- a/fpdfsdk/fsdk_baseform.cpp +++ b/fpdfsdk/fsdk_baseform.cpp @@ -350,19 +350,19 @@ void CPDFSDK_Widget::SynchronizeXFAValue(IXFA_DocView* pXFADocView, case FIELDTYPE_CHECKBOX: { if (CXFA_WidgetAcc* pWidgetAcc = pXFAWidgetHandler->GetDataAcc(hWidget)) { - FX_BOOL bChecked = pWidgetAcc->GetCheckState() == XFA_CHECKSTATE_On; - - pFormField->CheckControl(pFormField->GetControlIndex(pFormControl), - bChecked, TRUE); + pFormField->CheckControl( + pFormField->GetControlIndex(pFormControl), + pWidgetAcc->GetCheckState() == XFA_CHECKSTATE_On, true); } } break; case FIELDTYPE_RADIOBUTTON: { + // TODO(weili): Check whether we need to handle checkbox and radio + // button differently, otherwise, merge these two cases. if (CXFA_WidgetAcc* pWidgetAcc = pXFAWidgetHandler->GetDataAcc(hWidget)) { - FX_BOOL bChecked = pWidgetAcc->GetCheckState() == XFA_CHECKSTATE_On; - - pFormField->CheckControl(pFormField->GetControlIndex(pFormControl), - bChecked, TRUE); + pFormField->CheckControl( + pFormField->GetControlIndex(pFormControl), + pWidgetAcc->GetCheckState() == XFA_CHECKSTATE_On, true); } } break; case FIELDTYPE_TEXTFIELD: { |