summaryrefslogtreecommitdiff
path: root/forms
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-07-16 13:50:53 +0200
committerStephan Bergmann <sbergman@redhat.com>2015-07-16 14:00:17 +0200
commit891c80e1723c4aac2457d5a76b1b0e042e78b70b (patch)
treeda59f5fc1d19e5d3278f96f9a457cb2d3c3ebdcb /forms
parentd9dd11e16d2a6c7b9ed1a152db5d9a0c055399cb (diff)
loplugin:simplifybool
Change-Id: I8b704401233fa865c8ec4d4663d720a3d7d8de69
Diffstat (limited to 'forms')
-rw-r--r--forms/source/component/FormComponent.cxx4
-rw-r--r--forms/source/richtext/attributedispatcher.cxx2
-rw-r--r--forms/source/xforms/namedcollection.hxx2
3 files changed, 4 insertions, 4 deletions
diff --git a/forms/source/component/FormComponent.cxx b/forms/source/component/FormComponent.cxx
index 1b978d15c151..cc27283a22dc 100644
--- a/forms/source/component/FormComponent.cxx
+++ b/forms/source/component/FormComponent.cxx
@@ -321,12 +321,12 @@ void SAL_CALL OControl::setDesignMode(sal_Bool bOn) throw ( RuntimeException, st
sal_Bool SAL_CALL OControl::isDesignMode() throw ( RuntimeException, std::exception)
{
- return m_xControl.is() ? m_xControl->isDesignMode() : sal_True;
+ return !m_xControl.is() || m_xControl->isDesignMode();
}
sal_Bool SAL_CALL OControl::isTransparent() throw ( RuntimeException, std::exception)
{
- return m_xControl.is() ? m_xControl->isTransparent() : sal_True;
+ return !m_xControl.is() || m_xControl->isTransparent();
}
OBoundControl::OBoundControl( const Reference< XComponentContext >& _rxContext,
diff --git a/forms/source/richtext/attributedispatcher.cxx b/forms/source/richtext/attributedispatcher.cxx
index e6493b92519d..971d66a43b6c 100644
--- a/forms/source/richtext/attributedispatcher.cxx
+++ b/forms/source/richtext/attributedispatcher.cxx
@@ -68,7 +68,7 @@ namespace frm
FeatureStateEvent OAttributeDispatcher::buildStatusEvent() const
{
FeatureStateEvent aEvent( ORichTextFeatureDispatcher::buildStatusEvent() );
- aEvent.IsEnabled = getEditView() ? !getEditView()->IsReadOnly() : sal_False;
+ aEvent.IsEnabled = getEditView() && !getEditView()->IsReadOnly();
AttributeState aState;
if ( m_pMasterDispatcher )
diff --git a/forms/source/xforms/namedcollection.hxx b/forms/source/xforms/namedcollection.hxx
index dd4498d1e7e9..f411595310e6 100644
--- a/forms/source/xforms/namedcollection.hxx
+++ b/forms/source/xforms/namedcollection.hxx
@@ -127,7 +127,7 @@ public:
const OUString& aName )
throw( css::uno::RuntimeException ) SAL_OVERRIDE
{
- return hasItem( aName ) ? sal_True : sal_False;
+ return hasItem( aName );
}
};