summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-05-08 09:19:03 +0200
committerStephan Bergmann <sbergman@redhat.com>2015-05-08 09:49:01 +0200
commit1cb0b37ad09400138d7c4a5874c02f921e742d37 (patch)
tree952eabf4c88a16971a14723b83ae5da1557e1d85
parent61b44da9fbf35100ac96896f04dee5b779305d68 (diff)
Rephrase comparisons between bool and sal_Bool
...to cater for forthcoming loplugin:implicitboolconversion improvements Change-Id: I88c0c4681137022005c3a4c418e91cb17bc17148
-rw-r--r--animations/source/animcore/animcore.cxx8
-rw-r--r--avmedia/source/gstreamer/gstplayer.cxx2
-rw-r--r--package/source/xstor/xstorage.cxx2
-rw-r--r--svx/source/form/formfeaturedispatcher.cxx2
4 files changed, 7 insertions, 7 deletions
diff --git a/animations/source/animcore/animcore.cxx b/animations/source/animcore/animcore.cxx
index 429c866e84b7..cd67ed06eb42 100644
--- a/animations/source/animcore/animcore.cxx
+++ b/animations/source/animcore/animcore.cxx
@@ -1199,7 +1199,7 @@ sal_Bool SAL_CALL AnimationNode::getAutoReverse() throw (RuntimeException, std::
void SAL_CALL AnimationNode::setAutoReverse( sal_Bool _autoreverse ) throw (RuntimeException, std::exception)
{
Guard< Mutex > aGuard( maMutex );
- if( _autoreverse != (mbAutoReverse ? 1 : 0) )
+ if( bool(_autoreverse) != mbAutoReverse )
{
mbAutoReverse = _autoreverse;
fireChangeListener();
@@ -1466,7 +1466,7 @@ void SAL_CALL AnimationNode::setAccumulate( sal_Bool _accumulate )
throw (RuntimeException, std::exception)
{
Guard< Mutex > aGuard( maMutex );
- if( _accumulate != (mbAccumulate ? 1 : 0) )
+ if( bool(_accumulate) != mbAccumulate )
{
mbAccumulate = _accumulate;
fireChangeListener();
@@ -1647,7 +1647,7 @@ sal_Bool SAL_CALL AnimationNode::getDirection() throw (RuntimeException, std::ex
void SAL_CALL AnimationNode::setDirection( sal_Bool _direction ) throw (RuntimeException, std::exception)
{
Guard< Mutex > aGuard( maMutex );
- if( _direction != (mbDirection ? 1 : 0) )
+ if( bool(_direction) != mbDirection )
{
mbDirection = _direction;
fireChangeListener();
@@ -1773,7 +1773,7 @@ sal_Bool SAL_CALL AnimationNode::getMode() throw (RuntimeException, std::excepti
void SAL_CALL AnimationNode::setMode( sal_Bool _mode ) throw (RuntimeException, std::exception)
{
Guard< Mutex > aGuard( maMutex );
- if( _mode != (mbMode ? 1 : 0) )
+ if( bool(_mode) != mbMode )
{
mbMode = _mode;
fireChangeListener();
diff --git a/avmedia/source/gstreamer/gstplayer.cxx b/avmedia/source/gstreamer/gstplayer.cxx
index 111e7aea426d..1b06c174e759 100644
--- a/avmedia/source/gstreamer/gstplayer.cxx
+++ b/avmedia/source/gstreamer/gstplayer.cxx
@@ -541,7 +541,7 @@ void SAL_CALL Player::setMute( sal_Bool bSet )
DBG( "set mute: %d muted: %d unmuted volume: %lf", bSet, mbMuted, mnUnmutedVolume );
// change the volume to 0 or the unmuted volume
- if( mpPlaybin && (mbMuted ? 1 : 0) != bSet )
+ if( mpPlaybin && mbMuted != bool(bSet) )
{
double nVolume = mnUnmutedVolume;
if( bSet )
diff --git a/package/source/xstor/xstorage.cxx b/package/source/xstor/xstorage.cxx
index c499e019fe6b..63158f6bd7f5 100644
--- a/package/source/xstor/xstorage.cxx
+++ b/package/source/xstor/xstorage.cxx
@@ -4124,7 +4124,7 @@ void SAL_CALL OStorage::setModified( sal_Bool bModified )
if ( m_pData->m_bReadOnlyWrap )
throw beans::PropertyVetoException( THROW_WHERE ); // TODO: access denied
- if ( (m_pImpl->m_bIsModified ? 1 : 0) != bModified )
+ if ( m_pImpl->m_bIsModified != bool(bModified) )
m_pImpl->m_bIsModified = bModified;
aGuard.clear();
diff --git a/svx/source/form/formfeaturedispatcher.cxx b/svx/source/form/formfeaturedispatcher.cxx
index 2c18dbd3c30f..791543657ac6 100644
--- a/svx/source/form/formfeaturedispatcher.cxx
+++ b/svx/source/form/formfeaturedispatcher.cxx
@@ -68,7 +68,7 @@ namespace svx
FeatureStateEvent aUnoState;
getUnoState( aUnoState );
- if ( ( m_aLastKnownState == aUnoState.State ) && ( (m_bLastKnownEnabled ? 1 : 0) == aUnoState.IsEnabled ) )
+ if ( ( m_aLastKnownState == aUnoState.State ) && ( m_bLastKnownEnabled == bool(aUnoState.IsEnabled) ) )
return;
m_aLastKnownState = aUnoState.State;