diff options
author | Noel Grandin <noel@peralex.com> | 2013-01-09 16:30:29 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2013-01-28 08:23:03 +0200 |
commit | 29f17580a59421d7dd5f8c6bef980ae30cc63bb6 (patch) | |
tree | aa4681bd7afc32a6a5195c69e9180653136211f7 /svl/source | |
parent | 09cf6fe83a9d895dc6d5b3db91fd54aeaf4d0ea7 (diff) |
fdo#46808, Convert svl/lockfile code to XComponentContext
Change-Id: I380944aa5e16b160ac76f939a839c513d4fbf232
Diffstat (limited to 'svl/source')
-rw-r--r-- | svl/source/misc/documentlockfile.cxx | 6 | ||||
-rw-r--r-- | svl/source/misc/lockfilecommon.cxx | 6 | ||||
-rw-r--r-- | svl/source/misc/sharecontrolfile.cxx | 4 |
3 files changed, 6 insertions, 10 deletions
diff --git a/svl/source/misc/documentlockfile.cxx b/svl/source/misc/documentlockfile.cxx index cebc89b26b1c..5bb2d58eb63f 100644 --- a/svl/source/misc/documentlockfile.cxx +++ b/svl/source/misc/documentlockfile.cxx @@ -53,8 +53,8 @@ namespace svt { sal_Bool DocumentLockFile::m_bAllowInteraction = sal_True; // ---------------------------------------------------------------------- -DocumentLockFile::DocumentLockFile( const ::rtl::OUString& aOrigURL, const uno::Reference< lang::XMultiServiceFactory >& xFactory ) -: LockFileCommon( aOrigURL, xFactory, ::rtl::OUString( ".~lock." ) ) +DocumentLockFile::DocumentLockFile( const ::rtl::OUString& aOrigURL ) +: LockFileCommon( aOrigURL, ::rtl::OUString( ".~lock." ) ) { } @@ -92,7 +92,7 @@ sal_Bool DocumentLockFile::CreateOwnLockFile() try { uno::Reference< io::XStream > xTempFile( - io::TempFile::create(comphelper::getComponentContext(m_xFactory)), + io::TempFile::create( comphelper::getProcessComponentContext() ), uno::UNO_QUERY_THROW ); uno::Reference< io::XSeekable > xSeekable( xTempFile, uno::UNO_QUERY_THROW ); diff --git a/svl/source/misc/lockfilecommon.cxx b/svl/source/misc/lockfilecommon.cxx index 7df914d7f6f5..bb5ae628bf6b 100644 --- a/svl/source/misc/lockfilecommon.cxx +++ b/svl/source/misc/lockfilecommon.cxx @@ -54,12 +54,8 @@ using namespace ::com::sun::star; namespace svt { // ---------------------------------------------------------------------- -LockFileCommon::LockFileCommon( const ::rtl::OUString& aOrigURL, const uno::Reference< lang::XMultiServiceFactory >& xFactory, const ::rtl::OUString& aPrefix ) -: m_xFactory( xFactory ) +LockFileCommon::LockFileCommon( const ::rtl::OUString& aOrigURL, const ::rtl::OUString& aPrefix ) { - if ( !m_xFactory.is() ) - m_xFactory = ::comphelper::getProcessServiceFactory(); - INetURLObject aDocURL = ResolveLinks( INetURLObject( aOrigURL ) ); ::rtl::OUString aShareURLString = aDocURL.GetPartBeforeLastName(); diff --git a/svl/source/misc/sharecontrolfile.cxx b/svl/source/misc/sharecontrolfile.cxx index c0e7daa539bc..9d6c481d89a0 100644 --- a/svl/source/misc/sharecontrolfile.cxx +++ b/svl/source/misc/sharecontrolfile.cxx @@ -52,8 +52,8 @@ using namespace ::com::sun::star; namespace svt { // ---------------------------------------------------------------------- -ShareControlFile::ShareControlFile( const ::rtl::OUString& aOrigURL, const uno::Reference< lang::XMultiServiceFactory >& xFactory ) -: LockFileCommon( aOrigURL, xFactory, ::rtl::OUString( ".~sharing." ) ) +ShareControlFile::ShareControlFile( const ::rtl::OUString& aOrigURL ) +: LockFileCommon( aOrigURL, ::rtl::OUString( ".~sharing." ) ) { OpenStream(); |