diff options
Diffstat (limited to 'desktop/source/app/check_ext_deps.cxx')
-rw-r--r-- | desktop/source/app/check_ext_deps.cxx | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/desktop/source/app/check_ext_deps.cxx b/desktop/source/app/check_ext_deps.cxx index a5978696f6e5..7f76d155c31e 100644 --- a/desktop/source/app/check_ext_deps.cxx +++ b/desktop/source/app/check_ext_deps.cxx @@ -25,7 +25,7 @@ #include <sal/log.hxx> #include <cppuhelper/implbase.hxx> -#include <tools/diagnose_ex.h> +#include <comphelper/diagnose_ex.hxx> #include <toolkit/helper/vclunohelper.hxx> #include <comphelper/lok.hxx> @@ -51,6 +51,7 @@ #include <com/sun/star/util/XChangesBatch.hpp> #include <app.hxx> +#include <utility> #include <dp_misc.h> @@ -75,7 +76,7 @@ class SilentCommandEnv public: SilentCommandEnv( - uno::Reference<uno::XComponentContext> const & xContext, + uno::Reference<uno::XComponentContext> xContext, Desktop* pDesktop ); virtual ~SilentCommandEnv() override; @@ -97,9 +98,9 @@ public: SilentCommandEnv::SilentCommandEnv( - uno::Reference<uno::XComponentContext> const & xContext, + uno::Reference<uno::XComponentContext> xContext, Desktop* pDesktop ): - mxContext( xContext ), + mxContext(std::move( xContext )), mpDesktop( pDesktop ), mnLevel( 0 ), mnProgress( 25 ) @@ -207,7 +208,7 @@ void SilentCommandEnv::pop() } // end namespace -constexpr OUStringLiteral aAccessSrvc = u"com.sun.star.configuration.ConfigurationUpdateAccess"; +constexpr OUString aAccessSrvc = u"com.sun.star.configuration.ConfigurationUpdateAccess"_ustr; static sal_Int16 impl_showExtensionDialog( uno::Reference< uno::XComponentContext > const &xContext ) { @@ -254,13 +255,13 @@ static bool impl_checkDependencies( const uno::Reference< uno::XComponentContext e.Context, anyEx ); } -#ifdef DEBUG +#if OSL_DEBUG_LEVEL >= 2 sal_Int32 const nMax = 3; #else sal_Int32 const nMax = 2; #endif - for ( uno::Sequence< uno::Reference< deployment::XPackage > > const & xPackageList : std::as_const(xAllPackages) ) + for (uno::Sequence<uno::Reference<deployment::XPackage>> const& xPackageList : xAllPackages) { for ( sal_Int32 j = 0; (j<nMax) && (j < xPackageList.getLength()); ++j ) { @@ -316,12 +317,12 @@ static void impl_setNeedsCompatCheck() comphelper::getProcessComponentContext() ) ); beans::NamedValue v( "nodepath", - makeAny( OUString("org.openoffice.Setup/Office") ) ); + Any( OUString("org.openoffice.Setup/Office") ) ); Sequence< Any > theArgs{ Any(v) }; Reference< beans::XPropertySet > pset( theConfigProvider->createInstanceWithArguments( aAccessSrvc, theArgs ), UNO_QUERY_THROW ); - Any value = makeAny( OUString("never") ); + Any value( OUString("never") ); pset->setPropertyValue("LastCompatibilityCheckID", value ); Reference< util::XChangesBatch >( pset, UNO_QUERY_THROW )->commitChanges(); @@ -346,7 +347,7 @@ static bool impl_needsCompatCheck() comphelper::getProcessComponentContext() ) ); beans::NamedValue v( "nodepath", - makeAny( OUString("org.openoffice.Setup/Office") ) ); + Any( OUString("org.openoffice.Setup/Office") ) ); Sequence< Any > theArgs{ Any(v) }; Reference< beans::XPropertySet > pset( theConfigProvider->createInstanceWithArguments( aAccessSrvc, theArgs ), UNO_QUERY_THROW ); @@ -361,7 +362,7 @@ static bool impl_needsCompatCheck() pset->setPropertyValue("LastCompatibilityCheckID", result ); Reference< util::XChangesBatch >( pset, UNO_QUERY_THROW )->commitChanges(); } -#ifdef DEBUG +#if OSL_DEBUG_LEVEL >= 2 bNeedsCheck = true; #endif } |