diff --git a/UnoControls/source/base/basecontainercontrol.cxx b/UnoControls/source/base/basecontainercontrol.cxx index 7c1a9687d52f..93f7cc209b0c 100644 --- a/UnoControls/source/base/basecontainercontrol.cxx +++ b/UnoControls/source/base/basecontainercontrol.cxx @@ -60,7 +60,7 @@ Any SAL_CALL BaseContainerControl::queryInterface( const Type& rType ) throw( Ru // Don't use mutex or guard in this method!!! Is a method of XInterface. Any aReturn ; Reference< XInterface > xDel = BaseControl::impl_getDelegator(); - if ( xDel.is() == sal_True ) + if ( xDel.is() ) { // If an delegator exist, forward question to his queryInterface. // Delegator will ask his own queryAggregation! @@ -122,7 +122,7 @@ Any SAL_CALL BaseContainerControl::queryAggregation( const Type& aType ) throw( ); // If searched interface supported by this class ... - if ( aReturn.hasValue() == sal_True ) + if ( aReturn.hasValue() ) { // ... return this information. return aReturn ; @@ -141,7 +141,7 @@ Any SAL_CALL BaseContainerControl::queryAggregation( const Type& aType ) throw( void SAL_CALL BaseContainerControl::createPeer( const Reference< XToolkit >& xToolkit , const Reference< XWindowPeer >& xParent ) throw( RuntimeException ) { - if ( getPeer().is() == sal_False ) + if ( !getPeer().is() ) { // create own peer BaseControl::createPeer( xToolkit, xParent ); diff --git a/UnoControls/source/base/basecontrol.cxx b/UnoControls/source/base/basecontrol.cxx index b95f9d761123..0ba3dd92ac37 100644 --- a/UnoControls/source/base/basecontrol.cxx +++ b/UnoControls/source/base/basecontrol.cxx @@ -81,7 +81,7 @@ BaseControl::~BaseControl() Any SAL_CALL BaseControl::queryInterface( const Type& rType ) throw( RuntimeException ) { Any aReturn ; - if ( m_xDelegator.is() == sal_True ) + if ( m_xDelegator.is() ) { // If an delegator exist, forward question to his queryInterface. // Delegator will ask his own queryAggregation! @@ -221,7 +221,7 @@ Any SAL_CALL BaseControl::queryAggregation( const Type& aType ) throw( RuntimeEx ); // If searched interface supported by this class ... - if ( aReturn.hasValue() == sal_True ) + if ( aReturn.hasValue() ) { // ... return this information. return aReturn ; @@ -283,7 +283,7 @@ void SAL_CALL BaseControl::dispose() throw( RuntimeException ) impl_releasePeer(); // release view - if ( m_xGraphicsView.is() == sal_True ) + if ( m_xGraphicsView.is() ) { m_xGraphicsView.clear(); } @@ -321,7 +321,7 @@ void SAL_CALL BaseControl::createPeer( const Reference< XToolkit >& xToo // Ready for multithreading MutexGuard aGuard( m_aMutex ); - if ( m_xPeer.is() == sal_False ) + if ( !m_xPeer.is() ) { // use method "BaseControl::getWindowDescriptor()" fot change window attributes !!! WindowDescriptor* pDescriptor = impl_getWindowDescriptor( xParentPeer ); @@ -334,7 +334,7 @@ void SAL_CALL BaseControl::createPeer( const Reference< XToolkit >& xToo // very slow under remote conditions! // create the window on the server Reference< XToolkit > xLocalToolkit = xToolkit ; - if ( xLocalToolkit.is() == sal_False ) + if ( !xLocalToolkit.is() ) { // but first create well known toolkit, if it not exist xLocalToolkit = Reference< XToolkit > ( Toolkit::create(m_xComponentContext), UNO_QUERY_THROW ); @@ -345,7 +345,7 @@ void SAL_CALL BaseControl::createPeer( const Reference< XToolkit >& xToo // don't forget to release the memory! delete pDescriptor ; - if ( m_xPeerWindow.is() == sal_True ) + if ( m_xPeerWindow.is() ) { if ( m_pMultiplexer != NULL ) { @@ -356,12 +356,12 @@ void SAL_CALL BaseControl::createPeer( const Reference< XToolkit >& xToo // and add a paint listener Reference< XDevice > xDevice( m_xPeerWindow, UNO_QUERY ); - if ( xDevice.is() == sal_True ) + if ( xDevice.is() ) { m_xGraphicsPeer = xDevice->createGraphics(); } - if ( m_xGraphicsPeer.is() == sal_True ) + if ( m_xGraphicsPeer.is() ) { addPaintListener( this ); addWindowListener( this ); @@ -504,7 +504,7 @@ void SAL_CALL BaseControl::setVisible( sal_Bool bVisible ) throw( RuntimeExcepti // Set new state of flag m_bVisible = bVisible ; - if ( m_xPeerWindow.is() == sal_True ) + if ( m_xPeerWindow.is() ) { // Set it also on peerwindow m_xPeerWindow->setVisible( m_bVisible ); @@ -523,7 +523,7 @@ void SAL_CALL BaseControl::setEnable( sal_Bool bEnable ) throw( RuntimeException // Set new state of flag m_bEnable = bEnable ; - if ( m_xPeerWindow.is() == sal_True ) + if ( m_xPeerWindow.is() ) { // Set it also on peerwindow m_xPeerWindow->setEnable( m_bEnable ); @@ -539,7 +539,7 @@ void SAL_CALL BaseControl::setFocus() throw( RuntimeException ) // Ready for multithreading MutexGuard aGuard( m_aMutex ); - if ( m_xPeerWindow.is() == sal_True ) + if ( m_xPeerWindow.is() ) { m_xPeerWindow->setFocus(); } @@ -690,7 +690,7 @@ sal_Bool SAL_CALL BaseControl::setGraphics( const Reference< XGraphics >& xDevic // - in this class exist 2 graphics-member ... one for peer[_xGraphicsPeer] and one for view[_xGraphicsView] // - they are used by "windowPaint() and draw()", forwarded to "paint ()" sal_Bool bReturn = sal_False ; - if ( xDevice.is() == sal_True ) + if ( xDevice.is() ) { // Ready for multithreading MutexGuard aGuard( m_aMutex ); @@ -745,14 +745,14 @@ void SAL_CALL BaseControl::disposing( const EventObject& /*aSource*/ ) throw( Ru // - release ALL references // - it must be !!! - if ( m_xGraphicsPeer.is() == sal_True ) + if ( m_xGraphicsPeer.is() ) { removePaintListener( this ); removeWindowListener( this ); m_xGraphicsPeer.clear(); } - if ( m_xGraphicsView.is() == sal_True ) + if ( m_xGraphicsView.is() ) { m_xGraphicsView.clear(); } @@ -948,9 +948,9 @@ Reference< XInterface > BaseControl::impl_getDelegator() void BaseControl::impl_releasePeer() { - if ( m_xPeer.is() == sal_True ) + if ( m_xPeer.is() ) { - if ( m_xGraphicsPeer.is() == sal_True ) + if ( m_xGraphicsPeer.is() ) { removePaintListener( this ); removeWindowListener( this ); diff --git a/UnoControls/source/base/multiplexer.cxx b/UnoControls/source/base/multiplexer.cxx index 775760638967..416042bd970c 100644 --- a/UnoControls/source/base/multiplexer.cxx +++ b/UnoControls/source/base/multiplexer.cxx @@ -46,7 +46,7 @@ namespace unocontrols{ /* We must change the source of the event. */ \ aLocalEvent.Source = m_xControl ; \ /* Is the control not destroyed? */ \ - if( aLocalEvent.Source.is() == sal_True ) \ + if( aLocalEvent.Source.is() ) \ { \ if( aIterator.hasMoreElements() ) \ { \ @@ -116,7 +116,7 @@ Any SAL_CALL OMRCListenerMultiplexerHelper::queryInterface( const Type& rType ) ); // If searched interface supported by this class ... - if ( aReturn.hasValue() == sal_True ) + if ( aReturn.hasValue() ) { // ... return this information. return aReturn ; diff --git a/UnoControls/source/controls/OConnectionPointContainerHelper.cxx b/UnoControls/source/controls/OConnectionPointContainerHelper.cxx index 54f937064da3..b3e4f76d85b2 100644 --- a/UnoControls/source/controls/OConnectionPointContainerHelper.cxx +++ b/UnoControls/source/controls/OConnectionPointContainerHelper.cxx @@ -63,7 +63,7 @@ Any SAL_CALL OConnectionPointContainerHelper::queryInterface( const Type& aType ); // If searched interface not supported by this class ... - if ( aReturn.hasValue() == sal_False ) + if ( !aReturn.hasValue() ) { // ... ask baseclasses. aReturn = OWeakObject::queryInterface( aType ); diff --git a/UnoControls/source/controls/OConnectionPointHelper.cxx b/UnoControls/source/controls/OConnectionPointHelper.cxx index 24eb001014e3..af4410a7a6a8 100644 --- a/UnoControls/source/controls/OConnectionPointHelper.cxx +++ b/UnoControls/source/controls/OConnectionPointHelper.cxx @@ -68,7 +68,7 @@ Any SAL_CALL OConnectionPointHelper::queryInterface( const Type& aType ) throw( ); // If searched interface not supported by this class ... - if ( aReturn.hasValue() == sal_False ) + if ( !aReturn.hasValue() ) { // ... ask baseclasses. aReturn = OWeakObject::queryInterface( aType ); diff --git a/UnoControls/source/controls/framecontrol.cxx b/UnoControls/source/controls/framecontrol.cxx index 6c30ee8c0f6f..8c9601b34773 100644 --- a/UnoControls/source/controls/framecontrol.cxx +++ b/UnoControls/source/controls/framecontrol.cxx @@ -162,11 +162,11 @@ Any SAL_CALL FrameControl::queryAggregation( const Type& aType ) throw( RuntimeE ); // If searched interface not supported by this class ... - if ( aReturn.hasValue() == sal_False ) + if ( !aReturn.hasValue() ) { // ... ask baseclasses. aReturn = OPropertySetHelper::queryInterface( aType ); - if ( aReturn.hasValue() == sal_False ) + if ( !aReturn.hasValue() ) { aReturn = BaseControl::queryAggregation( aType ); } diff --git a/UnoControls/source/controls/progressbar.cxx b/UnoControls/source/controls/progressbar.cxx index aebf0f3e95a3..8df5d9ae39d4 100644 --- a/UnoControls/source/controls/progressbar.cxx +++ b/UnoControls/source/controls/progressbar.cxx @@ -157,7 +157,7 @@ Any SAL_CALL ProgressBar::queryAggregation( const Type& aType ) throw( RuntimeEx ); // If searched interface not supported by this class ... - if ( aReturn.hasValue() == sal_False ) + if ( !aReturn.hasValue() ) { // ... ask baseclasses. aReturn = BaseControl::queryAggregation( aType ); diff --git a/UnoControls/source/controls/progressmonitor.cxx b/UnoControls/source/controls/progressmonitor.cxx index ae1c2b91d737..ab4dd8a244a3 100644 --- a/UnoControls/source/controls/progressmonitor.cxx +++ b/UnoControls/source/controls/progressmonitor.cxx @@ -207,7 +207,7 @@ Any SAL_CALL ProgressMonitor::queryAggregation( const Type& aType ) throw( Runti ); // If searched interface not supported by this class ... - if ( aReturn.hasValue() == sal_False ) + if ( !aReturn.hasValue() ) { // ... ask baseclasses. aReturn = BaseControl::queryAggregation( aType ); diff --git a/UnoControls/source/controls/statusindicator.cxx b/UnoControls/source/controls/statusindicator.cxx index 03f0a3bd5985..49f76053e63b 100644 --- a/UnoControls/source/controls/statusindicator.cxx +++ b/UnoControls/source/controls/statusindicator.cxx @@ -167,7 +167,7 @@ Any SAL_CALL StatusIndicator::queryAggregation( const Type& aType ) throw( Runti ); // If searched interface not supported by this class ... - if ( aReturn.hasValue() == sal_False ) + if ( !aReturn.hasValue() ) { // ... ask baseclasses. aReturn = BaseControl::queryAggregation( aType ); @@ -308,7 +308,7 @@ void SAL_CALL StatusIndicator::createPeer ( const css::uno::Reference< XWindowPeer > & rParent ) throw( RuntimeException ) { - if( getPeer().is() == sal_False ) + if( !getPeer().is() ) { BaseContainerControl::createPeer( rToolkit, rParent ); @@ -447,18 +447,18 @@ void StatusIndicator::impl_paint ( sal_Int32 nX, sal_Int32 nY, const css::uno::R // background = gray css::uno::Reference< XWindowPeer > xPeer( impl_getPeerWindow(), UNO_QUERY ); - if( xPeer.is() == sal_True ) + if( xPeer.is() ) xPeer->setBackground( STATUSINDICATOR_BACKGROUNDCOLOR ); // FixedText background = gray css::uno::Reference< XControl > xTextControl( m_xText, UNO_QUERY ); xPeer = xTextControl->getPeer(); - if( xPeer.is() == sal_True ) + if( xPeer.is() ) xPeer->setBackground( STATUSINDICATOR_BACKGROUNDCOLOR ); // Progress background = gray xPeer = m_xProgressBar->getPeer(); - if( xPeer.is() == sal_True ) + if( xPeer.is() ) xPeer->setBackground( STATUSINDICATOR_BACKGROUNDCOLOR ); // paint shadow border