diff options
author | Lei Zhang <thestig@chromium.org> | 2015-10-20 10:21:36 -0700 |
---|---|---|
committer | Lei Zhang <thestig@chromium.org> | 2015-10-20 10:21:36 -0700 |
commit | 23378cdf2c0be861bddfffd82aed8cd6b07d77bf (patch) | |
tree | 325cc64b1d407e56bd603b01f3a08ec32144f2f1 /xfa/src/fwl | |
parent | dd11f8615fc20e638fbb6f6281c4564ed8927af3 (diff) | |
download | pdfium-23378cdf2c0be861bddfffd82aed8cd6b07d77bf.tar.xz |
XFA: Remove cond ? TRUE : FALSE.
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1409323003 .
Diffstat (limited to 'xfa/src/fwl')
-rw-r--r-- | xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp | 6 | ||||
-rw-r--r-- | xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp | 6 | ||||
-rw-r--r-- | xfa/src/fwl/src/core/fwl_formimp.cpp | 2 |
3 files changed, 7 insertions, 7 deletions
diff --git a/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp b/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp index 4460a8d0e1..64e9b40c11 100644 --- a/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_comboboximp.cpp @@ -869,13 +869,13 @@ FX_BOOL CFWL_ComboBoxImp::EditPaste(const CFX_WideString& wsPaste) { return m_pEdit->Paste(wsPaste);
}
FX_BOOL CFWL_ComboBoxImp::EditSelectAll() {
- return (m_pEdit->AddSelRange(0) == FWL_ERR_Succeeded) ? TRUE : FALSE;
+ return m_pEdit->AddSelRange(0) == FWL_ERR_Succeeded;
}
FX_BOOL CFWL_ComboBoxImp::EditDelete() {
- return (m_pEdit->ClearText() == FWL_ERR_Succeeded) ? TRUE : FALSE;
+ return m_pEdit->ClearText() == FWL_ERR_Succeeded;
}
FX_BOOL CFWL_ComboBoxImp::EditDeSelect() {
- return (m_pEdit->ClearSelections() == FWL_ERR_Succeeded) ? TRUE : FALSE;
+ return m_pEdit->ClearSelections() == FWL_ERR_Succeeded;
}
FWL_ERR CFWL_ComboBoxImp::GetBBox(CFX_RectF& rect) {
if (m_pWidgetMgr->IsFormDisabled()) {
diff --git a/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp b/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp index c378ccde02..866dc492aa 100644 --- a/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp +++ b/xfa/src/fwl/src/basewidget/fwl_datetimepickerimp.cpp @@ -662,13 +662,13 @@ FX_BOOL CFWL_DateTimePickerImp::Paste(const CFX_WideString& wsPaste) { return m_pEdit->Paste(wsPaste);
}
FX_BOOL CFWL_DateTimePickerImp::SelectAll() {
- return (m_pEdit->AddSelRange(0) == FWL_ERR_Succeeded) ? TRUE : FALSE;
+ return m_pEdit->AddSelRange(0) == FWL_ERR_Succeeded;
}
FX_BOOL CFWL_DateTimePickerImp::Delete() {
- return (m_pEdit->ClearText() == FWL_ERR_Succeeded) ? TRUE : FALSE;
+ return m_pEdit->ClearText() == FWL_ERR_Succeeded;
}
FX_BOOL CFWL_DateTimePickerImp::DeSelect() {
- return (m_pEdit->ClearSelections() == FWL_ERR_Succeeded) ? TRUE : FALSE;
+ return m_pEdit->ClearSelections() == FWL_ERR_Succeeded;
}
FWL_ERR CFWL_DateTimePickerImp::GetBBox(CFX_RectF& rect) {
if (m_pWidgetMgr->IsFormDisabled()) {
diff --git a/xfa/src/fwl/src/core/fwl_formimp.cpp b/xfa/src/fwl/src/core/fwl_formimp.cpp index 85139ca1a1..2facbf3757 100644 --- a/xfa/src/fwl/src/core/fwl_formimp.cpp +++ b/xfa/src/fwl/src/core/fwl_formimp.cpp @@ -885,7 +885,7 @@ void CFWL_FormImp::SetThemeData() { }
FX_BOOL CFWL_FormImp::HasIcon() {
IFWL_FormDP* pData = (IFWL_FormDP*)m_pProperties->m_pDataProvider;
- return pData->GetIcon(m_pInterface, FALSE) ? TRUE : FALSE;
+ return !!pData->GetIcon(m_pInterface, FALSE);
}
void CFWL_FormImp::UpdateIcon() {
CFWL_WidgetMgr* pWidgetMgr = (CFWL_WidgetMgr*)FWL_GetWidgetMgr();
|