diff options
author | Noel Grandin <noel@peralex.com> | 2016-02-26 14:44:03 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2016-02-29 08:04:06 +0200 |
commit | 1110346b3b8e57a190366aabebb62e53c6ab6d01 (patch) | |
tree | aa22f8f28cab116834e4222ef03206a7e0b0d29d | |
parent | 2b24b6b6c3b18d7d934b3f76cc7a787c498ece4a (diff) |
loplugin:unuseddefaultparam in unotools
Change-Id: Icb2dc74263026d90b7998b3fd880fd5d2c67a3b7
-rw-r--r-- | include/unotools/confignode.hxx | 2 | ||||
-rw-r--r-- | include/unotools/fontcfg.hxx | 5 | ||||
-rw-r--r-- | include/unotools/fontcvt.hxx | 8 | ||||
-rw-r--r-- | include/unotools/ucbhelper.hxx | 2 | ||||
-rw-r--r-- | include/unotools/ucbstreamhelper.hxx | 9 | ||||
-rw-r--r-- | unotools/source/config/confignode.cxx | 4 | ||||
-rw-r--r-- | unotools/source/config/fontcfg.cxx | 5 | ||||
-rw-r--r-- | unotools/source/misc/fontcvt.cxx | 4 | ||||
-rw-r--r-- | unotools/source/ucbhelper/ucbhelper.cxx | 4 | ||||
-rw-r--r-- | unotools/source/ucbhelper/ucbstreamhelper.cxx | 15 | ||||
-rw-r--r-- | unoxml/source/rdf/librdf_repository.cxx | 8 |
11 files changed, 26 insertions, 40 deletions
diff --git a/include/unotools/confignode.hxx b/include/unotools/confignode.hxx index d46ecda77121..264842d3b739 100644 --- a/include/unotools/confignode.hxx +++ b/include/unotools/confignode.hxx @@ -279,7 +279,7 @@ namespace utl given node path does not exist) are still asserted.</p> */ static OConfigurationTreeRoot tryCreateWithComponentContext( const css::uno::Reference< css::uno::XComponentContext >& rxContext, - const OUString& _rPath, sal_Int32 _nDepth = -1, CREATION_MODE _eMode = CM_UPDATABLE, bool _bLazyWrite = true ); + const OUString& _rPath, sal_Int32 _nDepth = -1, CREATION_MODE _eMode = CM_UPDATABLE ); /** commit all changes made on the subtree the object is the root for<p/> All changes made on any OConfigurationNode object retrieved (maybe indirect) from this root diff --git a/include/unotools/fontcfg.hxx b/include/unotools/fontcfg.hxx index a37242932dfa..4b388b79ed79 100644 --- a/include/unotools/fontcfg.hxx +++ b/include/unotools/fontcfg.hxx @@ -173,10 +173,7 @@ public: static FontSubstConfiguration& get(); - const FontNameAttr* getSubstInfo( - const OUString& rFontName, - const LanguageTag& rLanguageTag = LanguageTag( OUString( "en")) - ) const; + const FontNameAttr* getSubstInfo( const OUString& rFontName ) const; static void getMapName( const OUString& rOrgName, OUString& rShortName, OUString& rFamilyName, FontWeight& rWeight, FontWidth& rWidth, ImplFontAttrs& rType ); }; diff --git a/include/unotools/fontcvt.hxx b/include/unotools/fontcvt.hxx index d8080734ea5e..df8003b2063a 100644 --- a/include/unotools/fontcvt.hxx +++ b/include/unotools/fontcvt.hxx @@ -57,13 +57,11 @@ public: }; -// with bPerfect set the converter will only try and convert symbols which have -// perfect mappings to the windows symbols fonts. With it not set, it will -// allow somewhat more dubious transformations that are nevertheless -// recognizably similar. Even in this mode there will be characters that fail. +// The converter will allow somewhat dubious mappings to the the windows symbols fonts, +// that are nevertheless recognizably similar. Even in this mode there will be characters that fail. // The users of this might want to make a distinction between failed characters // which were inside and those outside the unicode private area. -UNOTOOLS_DLLPUBLIC StarSymbolToMSMultiFont *CreateStarSymbolToMSMultiFont(bool bPerfectOnly=false); +UNOTOOLS_DLLPUBLIC StarSymbolToMSMultiFont *CreateStarSymbolToMSMultiFont(); #endif // INCLUDED_UNOTOOLS_FONTCVT_HXX diff --git a/include/unotools/ucbhelper.hxx b/include/unotools/ucbhelper.hxx index 1b25c54369e6..e7cd434316a2 100644 --- a/include/unotools/ucbhelper.hxx +++ b/include/unotools/ucbhelper.hxx @@ -57,7 +57,7 @@ UNOTOOLS_DLLPUBLIC css::uno::Any GetProperty( UNOTOOLS_DLLPUBLIC bool MakeFolder( ucbhelper::Content & parent, OUString const & title, - ucbhelper::Content & result, bool exclusive = false); + ucbhelper::Content & result); /// like mkdir -p UNOTOOLS_DLLPUBLIC bool ensureFolder( diff --git a/include/unotools/ucbstreamhelper.hxx b/include/unotools/ucbstreamhelper.hxx index 47e34bc830b7..2e8308b13a3b 100644 --- a/include/unotools/ucbstreamhelper.hxx +++ b/include/unotools/ucbstreamhelper.hxx @@ -52,14 +52,11 @@ namespace utl class UNOTOOLS_DLLPUBLIC UcbStreamHelper : public SvStream { public: + static SvStream* CreateStream( const OUString& rFileName, StreamMode eOpenMode ); static SvStream* CreateStream( const OUString& rFileName, StreamMode eOpenMode, - UcbLockBytesHandler* pHandler=nullptr ); + css::uno::Reference < css::task::XInteractionHandler > ); static SvStream* CreateStream( const OUString& rFileName, StreamMode eOpenMode, - css::uno::Reference < css::task::XInteractionHandler >, - UcbLockBytesHandler* pHandler=nullptr ); - static SvStream* CreateStream( const OUString& rFileName, StreamMode eOpenMode, - bool bFileExists, - UcbLockBytesHandler* pHandler=nullptr ); + bool bFileExists ); static SvStream* CreateStream( css::uno::Reference < css::io::XInputStream > xStream ); static SvStream* CreateStream( css::uno::Reference < css::io::XStream > xStream ); static SvStream* CreateStream( css::uno::Reference < css::io::XInputStream > xStream, bool bCloseStream ); diff --git a/unotools/source/config/confignode.cxx b/unotools/source/config/confignode.cxx index e1b31cc0db76..827973221273 100644 --- a/unotools/source/config/confignode.cxx +++ b/unotools/source/config/confignode.cxx @@ -551,13 +551,13 @@ namespace utl } OConfigurationTreeRoot OConfigurationTreeRoot::tryCreateWithComponentContext( const Reference< XComponentContext >& rxContext, - const OUString& _rPath, sal_Int32 _nDepth , CREATION_MODE _eMode , bool _bLazyWrite ) + const OUString& _rPath, sal_Int32 _nDepth , CREATION_MODE _eMode ) { OSL_ENSURE( rxContext.is(), "OConfigurationTreeRoot::tryCreateWithComponentContext: invalid XComponentContext!" ); try { Reference< XMultiServiceFactory > xConfigFactory = theDefaultProvider::get( rxContext ); - return createWithProvider( xConfigFactory, _rPath, _nDepth, _eMode, _bLazyWrite ); + return createWithProvider( xConfigFactory, _rPath, _nDepth, _eMode ); } catch(const Exception&) { diff --git a/unotools/source/config/fontcfg.cxx b/unotools/source/config/fontcfg.cxx index 2b5105a26f78..e310b6ae5f88 100644 --- a/unotools/source/config/fontcfg.cxx +++ b/unotools/source/config/fontcfg.cxx @@ -1099,8 +1099,7 @@ void FontSubstConfiguration::readLocaleSubst( const OUString& rBcp47 ) const } } -const FontNameAttr* FontSubstConfiguration::getSubstInfo( const OUString& rFontName, - const LanguageTag& rLanguageTag ) const +const FontNameAttr* FontSubstConfiguration::getSubstInfo( const OUString& rFontName ) const { if( rFontName.isEmpty() ) return nullptr; @@ -1111,7 +1110,7 @@ const FontNameAttr* FontSubstConfiguration::getSubstInfo( const OUString& rFontN FontNameAttr aSearchAttr; aSearchAttr.Name = aSearchFont; - LanguageTag aLanguageTag( rLanguageTag); + LanguageTag aLanguageTag("en"); if( aLanguageTag.isSystemLocale() ) aLanguageTag = SvtSysLocale().GetUILanguageTag(); diff --git a/unotools/source/misc/fontcvt.cxx b/unotools/source/misc/fontcvt.cxx index f60d285763e2..9188293474d3 100644 --- a/unotools/source/misc/fontcvt.cxx +++ b/unotools/source/misc/fontcvt.cxx @@ -1238,9 +1238,9 @@ OUString StarSymbolToMSMultiFontImpl::ConvertChar(sal_Unicode &rChar) return sRet; } -StarSymbolToMSMultiFont *CreateStarSymbolToMSMultiFont(bool bPerfectOnly) +StarSymbolToMSMultiFont *CreateStarSymbolToMSMultiFont() { - return new StarSymbolToMSMultiFontImpl(bPerfectOnly); + return new StarSymbolToMSMultiFontImpl(false/*bPerfectOnly*/); } sal_Unicode ConvertChar::RecodeChar( sal_Unicode cChar ) const diff --git a/unotools/source/ucbhelper/ucbhelper.cxx b/unotools/source/ucbhelper/ucbhelper.cxx index 5519419f90a9..427cad2ebef6 100644 --- a/unotools/source/ucbhelper/ucbhelper.cxx +++ b/unotools/source/ucbhelper/ucbhelper.cxx @@ -225,7 +225,7 @@ bool utl::UCBContentHelper::Kill(OUString const & url) { bool utl::UCBContentHelper::MakeFolder( ucbhelper::Content & parent, OUString const & title, - ucbhelper::Content & result, bool exclusive) + ucbhelper::Content & result) { bool exists = false; try { @@ -276,7 +276,7 @@ bool utl::UCBContentHelper::MakeFolder( << e.getValueType().getTypeName() << " \"" << e.get<css::uno::Exception>().Message << '"'); } - if (exists && !exclusive) { + if (exists) { INetURLObject o(parent.getURL()); o.Append(title); result = content(o); diff --git a/unotools/source/ucbhelper/ucbstreamhelper.cxx b/unotools/source/ucbhelper/ucbstreamhelper.cxx index 4025b7738f16..07421c56368b 100644 --- a/unotools/source/ucbhelper/ucbstreamhelper.cxx +++ b/unotools/source/ucbhelper/ucbstreamhelper.cxx @@ -138,24 +138,21 @@ static SvStream* lcl_CreateStream( const OUString& rFileName, StreamMode eOpenMo return pStream; } -SvStream* UcbStreamHelper::CreateStream( const OUString& rFileName, StreamMode eOpenMode, - UcbLockBytesHandler* pHandler ) +SvStream* UcbStreamHelper::CreateStream( const OUString& rFileName, StreamMode eOpenMode ) { - return lcl_CreateStream( rFileName, eOpenMode, Reference < XInteractionHandler >(), pHandler, true /* bEnsureFileExists */ ); + return lcl_CreateStream( rFileName, eOpenMode, Reference < XInteractionHandler >(), nullptr, true /* bEnsureFileExists */ ); } SvStream* UcbStreamHelper::CreateStream( const OUString& rFileName, StreamMode eOpenMode, - Reference < XInteractionHandler > xInteractionHandler, - UcbLockBytesHandler* pHandler ) + Reference < XInteractionHandler > xInteractionHandler ) { - return lcl_CreateStream( rFileName, eOpenMode, xInteractionHandler, pHandler, true /* bEnsureFileExists */ ); + return lcl_CreateStream( rFileName, eOpenMode, xInteractionHandler, nullptr, true /* bEnsureFileExists */ ); } SvStream* UcbStreamHelper::CreateStream( const OUString& rFileName, StreamMode eOpenMode, - bool bFileExists, - UcbLockBytesHandler* pHandler ) + bool bFileExists ) { - return lcl_CreateStream( rFileName, eOpenMode, Reference < XInteractionHandler >(), pHandler, !bFileExists ); + return lcl_CreateStream( rFileName, eOpenMode, Reference < XInteractionHandler >(), nullptr, !bFileExists ); } SvStream* UcbStreamHelper::CreateStream( Reference < XInputStream > xStream ) diff --git a/unoxml/source/rdf/librdf_repository.cxx b/unoxml/source/rdf/librdf_repository.cxx index c72df2dcf7dd..04e0f7f5c35b 100644 --- a/unoxml/source/rdf/librdf_repository.cxx +++ b/unoxml/source/rdf/librdf_repository.cxx @@ -375,8 +375,7 @@ public: const uno::Reference< rdf::XResource > & i_xSubject, const uno::Reference< rdf::XURI > & i_xPredicate, const uno::Reference< rdf::XNode > & i_xObject, - const uno::Reference< rdf::XURI > & i_xName, - bool i_Internal = false ); + const uno::Reference< rdf::XURI > & i_xName ); // throw (uno::RuntimeException, lang::IllegalArgumentException, // container::NoSuchElementException, rdf::RepositoryException); void addStatementGraph_Lock( @@ -1805,8 +1804,7 @@ void librdf_Repository::addStatementGraph_NoLock( const uno::Reference< rdf::XResource > & i_xSubject, const uno::Reference< rdf::XURI > & i_xPredicate, const uno::Reference< rdf::XNode > & i_xObject, - const uno::Reference< rdf::XURI > & i_xGraphName, - bool i_Internal) + const uno::Reference< rdf::XURI > & i_xGraphName) //throw (uno::RuntimeException, lang::IllegalArgumentException, // container::NoSuchElementException, rdf::RepositoryException) { @@ -1832,7 +1830,7 @@ void librdf_Repository::addStatementGraph_NoLock( ::osl::MutexGuard g(m_aMutex); // don't call i_x* with mutex locked - addStatementGraph_Lock(stmt, contextU, i_Internal); + addStatementGraph_Lock(stmt, contextU, false/*i_Internal*/); } void librdf_Repository::addStatementGraph_Lock( |