From 2ff8ae7c9e9b36d187abef9e163f47a740d51214 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 23 Apr 2014 13:25:43 +0200 Subject: scripting: sal_Bool->bool Change-Id: I1550c49cce2ad64f9d62b06ec20512a750f83b84 --- scripting/source/basprov/baslibnode.cxx | 2 +- scripting/source/basprov/basmethnode.cxx | 4 ++-- scripting/source/basprov/basmodnode.cxx | 4 ++-- scripting/source/basprov/basprov.cxx | 2 +- scripting/source/protocolhandler/scripthandler.cxx | 6 +++--- scripting/source/provider/BrowseNodeFactoryImpl.cxx | 10 +++++----- scripting/source/provider/MasterScriptProvider.cxx | 4 ++-- scripting/source/stringresource/stringresource.cxx | 14 +++++++------- scripting/source/stringresource/stringresource.hxx | 8 ++++---- 9 files changed, 27 insertions(+), 27 deletions(-) (limited to 'scripting') diff --git a/scripting/source/basprov/baslibnode.cxx b/scripting/source/basprov/baslibnode.cxx index 70ab2e82cbbf..3943c3470f7f 100644 --- a/scripting/source/basprov/baslibnode.cxx +++ b/scripting/source/basprov/baslibnode.cxx @@ -115,7 +115,7 @@ namespace basprov { SolarMutexGuard aGuard; - sal_Bool bReturn = sal_False; + bool bReturn = false; if ( m_xLibrary.is() ) bReturn = m_xLibrary->hasElements(); diff --git a/scripting/source/basprov/basmethnode.cxx b/scripting/source/basprov/basmethnode.cxx index 5b600ee48666..8a1f823c4c35 100644 --- a/scripting/source/basprov/basmethnode.cxx +++ b/scripting/source/basprov/basmethnode.cxx @@ -312,9 +312,9 @@ namespace basprov sal_Bool BasicMethodNodeImpl::hasMethod( const OUString& aName ) throw (RuntimeException, std::exception) { - sal_Bool bReturn = sal_False; + bool bReturn = false; if ( aName == BASPROV_PROPERTY_EDITABLE ) - bReturn = sal_True; + bReturn = true; return bReturn; } diff --git a/scripting/source/basprov/basmodnode.cxx b/scripting/source/basprov/basmodnode.cxx index 7c548cbaeaaa..645931103464 100644 --- a/scripting/source/basprov/basmodnode.cxx +++ b/scripting/source/basprov/basmodnode.cxx @@ -116,12 +116,12 @@ namespace basprov { SolarMutexGuard aGuard; - sal_Bool bReturn = sal_False; + bool bReturn = false; if ( m_pModule ) { SbxArray* pMethods = m_pModule->GetMethods(); if ( pMethods && pMethods->Count() > 0 ) - bReturn = sal_True; + bReturn = true; } return bReturn; diff --git a/scripting/source/basprov/basprov.cxx b/scripting/source/basprov/basprov.cxx index e7360234027a..9c87bc3334d0 100644 --- a/scripting/source/basprov/basprov.cxx +++ b/scripting/source/basprov/basprov.cxx @@ -490,7 +490,7 @@ namespace basprov { SolarMutexGuard aGuard; - sal_Bool bReturn = sal_False; + bool bReturn = false; Reference< script::XLibraryContainer > xLibContainer; if ( m_bIsAppScriptCtx ) { diff --git a/scripting/source/protocolhandler/scripthandler.cxx b/scripting/source/protocolhandler/scripthandler.cxx index cb32a6deff0c..50fa627a9e6f 100644 --- a/scripting/source/protocolhandler/scripthandler.cxx +++ b/scripting/source/protocolhandler/scripthandler.cxx @@ -137,7 +137,7 @@ void SAL_CALL ScriptProtocolHandler::dispatchWithNotification( throw ( RuntimeException, std::exception ) { - sal_Bool bSuccess = sal_False; + bool bSuccess = false; Any invokeResult; bool bCaughtException = false; Any aException; @@ -196,14 +196,14 @@ void SAL_CALL ScriptProtocolHandler::dispatchWithNotification( if ( bIsDocumentScript ) pUndoGuard.reset( new ::framework::DocumentUndoGuard( m_xScriptInvocation ) ); - bSuccess = sal_False; + bSuccess = false; while ( !bSuccess ) { Any aFirstCaughtException; try { invokeResult = xFunc->invoke( inArgs, outIndex, outArgs ); - bSuccess = sal_True; + bSuccess = true; } catch( const provider::ScriptFrameworkErrorException& se ) { diff --git a/scripting/source/provider/BrowseNodeFactoryImpl.cxx b/scripting/source/provider/BrowseNodeFactoryImpl.cxx index 156b3876127e..9941f6b6f1da 100644 --- a/scripting/source/provider/BrowseNodeFactoryImpl.cxx +++ b/scripting/source/provider/BrowseNodeFactoryImpl.cxx @@ -334,9 +334,9 @@ Sequence< Reference< browse::XBrowseNode > > getAllBrowseNodes( const Reference< if( xCurrentController.is() ) { utl::MediaDescriptor aMD( model->getArgs() ); - sal_Bool bDefault = false; - sal_Bool bHidden = aMD.getUnpackedValueOrDefault( utl::MediaDescriptor::PROP_HIDDEN(), bDefault ); - sal_Bool bPreview = aMD.getUnpackedValueOrDefault( utl::MediaDescriptor::PROP_PREVIEW(), bDefault ); + bool bDefault = false; + bool bHidden = aMD.getUnpackedValueOrDefault( utl::MediaDescriptor::PROP_HIDDEN(), bDefault ); + bool bPreview = aMD.getUnpackedValueOrDefault( utl::MediaDescriptor::PROP_PREVIEW(), bDefault ); if( !bHidden && !bPreview ) { Reference< document::XEmbeddedScripts > xScripts( model, UNO_QUERY ); @@ -587,10 +587,10 @@ public: hasChildNodes() throw ( RuntimeException, std::exception ) SAL_OVERRIDE { - sal_Bool result = sal_True; + bool result = true; if ( !m_vNodes.size() ) { - result = sal_False; + result = false; } return result; } diff --git a/scripting/source/provider/MasterScriptProvider.cxx b/scripting/source/provider/MasterScriptProvider.cxx index 850d45bc03fa..0ae25ec6a3a0 100644 --- a/scripting/source/provider/MasterScriptProvider.cxx +++ b/scripting/source/provider/MasterScriptProvider.cxx @@ -673,7 +673,7 @@ MasterScriptProvider::getByName( const OUString& aName ) throw ( container::NoSu sal_Bool SAL_CALL MasterScriptProvider::hasByName( const OUString& aName ) throw (RuntimeException, std::exception) { - sal_Bool result = sal_False; + bool result = false; if ( !m_bIsPkgMSP ) { if ( m_xMSPPkg.is() ) @@ -728,7 +728,7 @@ MasterScriptProvider::hasByName( const OUString& aName ) throw (RuntimeException try { result = xCont->hasByName( aName ); - if ( result == sal_True ) + if ( result ) { break; } diff --git a/scripting/source/stringresource/stringresource.cxx b/scripting/source/stringresource/stringresource.cxx index feac457a444f..910a165d44fa 100644 --- a/scripting/source/stringresource/stringresource.cxx +++ b/scripting/source/stringresource/stringresource.cxx @@ -215,7 +215,7 @@ OUString StringResourceImpl::resolveStringForLocale( const OUString& ResourceID, return implResolveString( ResourceID, pLocaleItem ); } -sal_Bool StringResourceImpl::implHasEntryForId( const OUString& ResourceID, LocaleItem* pLocaleItem ) +bool StringResourceImpl::implHasEntryForId( const OUString& ResourceID, LocaleItem* pLocaleItem ) { bool bSuccess = false; if( pLocaleItem != NULL && loadLocale( pLocaleItem ) ) @@ -341,7 +341,7 @@ sal_Bool StringResourceImpl::isReadOnly() } void StringResourceImpl::implSetCurrentLocale( const Locale& locale, - sal_Bool FindClosestMatch, sal_Bool bUseDefaultIfNoMatch ) + bool FindClosestMatch, bool bUseDefaultIfNoMatch ) throw (IllegalArgumentException, RuntimeException) { ::osl::MutexGuard aGuard( getMutex() ); @@ -368,7 +368,7 @@ void StringResourceImpl::implSetCurrentLocale( const Locale& locale, void StringResourceImpl::setCurrentLocale( const Locale& locale, sal_Bool FindClosestMatch ) throw (IllegalArgumentException, RuntimeException, std::exception) { - sal_Bool bUseDefaultIfNoMatch = false; + bool bUseDefaultIfNoMatch = false; implSetCurrentLocale( locale, FindClosestMatch, bUseDefaultIfNoMatch ); } @@ -559,7 +559,7 @@ void StringResourceImpl::removeLocale( const Locale& locale ) } if( m_pCurrentLocaleItem == pRemoveItem ) { - sal_Bool FindClosestMatch = false; + bool FindClosestMatch = false; setCurrentLocale( pFallbackItem->m_locale, FindClosestMatch ); } if( m_pDefaultLocaleItem == pRemoveItem ) @@ -642,7 +642,7 @@ sal_Int32 StringResourceImpl::getUniqueNumericId( ) // Private helper methods LocaleItem* StringResourceImpl::getItemForLocale - ( const Locale& locale, sal_Bool bException ) + ( const Locale& locale, bool bException ) throw (::com::sun::star::lang::IllegalArgumentException) { LocaleItem* pRetItem = NULL; @@ -839,8 +839,8 @@ void StringResourcePersistenceImpl::implInitializeCommonParameters implScanLocales(); - sal_Bool FindClosestMatch = true; - sal_Bool bUseDefaultIfNoMatch = true; + bool FindClosestMatch = true; + bool bUseDefaultIfNoMatch = true; implSetCurrentLocale( aCurrentLocale, FindClosestMatch, bUseDefaultIfNoMatch ); } diff --git a/scripting/source/stringresource/stringresource.hxx b/scripting/source/stringresource/stringresource.hxx index b0e6a37023ac..5a74e6e43eaa 100644 --- a/scripting/source/stringresource/stringresource.hxx +++ b/scripting/source/stringresource/stringresource.hxx @@ -63,7 +63,7 @@ struct hashName_Impl struct eqName_Impl { - sal_Bool operator()(const OUString& Str1, const OUString& Str2) const + bool operator()(const OUString& Str1, const OUString& Str2) const { return ( Str1 == Str2 ); } @@ -148,14 +148,14 @@ protected: // Returns the LocalItem for a given locale, if it exists, otherwise NULL // This method compares the locales exactly, no closest match search is performed - LocaleItem* getItemForLocale( const ::com::sun::star::lang::Locale& locale, sal_Bool bException ) + LocaleItem* getItemForLocale( const ::com::sun::star::lang::Locale& locale, bool bException ) throw (::com::sun::star::lang::IllegalArgumentException); // Returns the LocalItem for a given locale, if it exists, otherwise NULL // This method performes a closest match search, at least the language must match LocaleItem* getClosestMatchItemForLocale( const ::com::sun::star::lang::Locale& locale ); void implSetCurrentLocale( const ::com::sun::star::lang::Locale& locale, - sal_Bool FindClosestMatch, sal_Bool bUseDefaultIfNoMatch ) + bool FindClosestMatch, bool bUseDefaultIfNoMatch ) throw (::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException); void implModified( void ); @@ -164,7 +164,7 @@ protected: //=== Impl methods for ...ForLocale methods === OUString SAL_CALL implResolveString( const OUString& ResourceID, LocaleItem* pLocaleItem ) throw (::com::sun::star::resource::MissingResourceException); - sal_Bool implHasEntryForId( const OUString& ResourceID, LocaleItem* pLocaleItem ); + bool implHasEntryForId( const OUString& ResourceID, LocaleItem* pLocaleItem ); ::com::sun::star::uno::Sequence< OUString > implGetResourceIDs( LocaleItem* pLocaleItem ); void implSetString( const OUString& ResourceID, const OUString& Str, LocaleItem* pLocaleItem ); -- cgit