diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-09-18 11:51:16 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-09-18 14:27:53 +0000 |
commit | 1de1b63c2243c8b89789a180bfeed3bbb2ff01ae (patch) | |
tree | 7071cc0e77e2813db8cab0a7806008b5ae690a9d /extensions | |
parent | 335704695d15f53518a614060e60821c8e1cf279 (diff) |
boost->std
Change-Id: Id55e334156628a916ce15fca8ec618eed0ae9366
Reviewed-on: https://gerrit.libreoffice.org/18683
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'extensions')
-rw-r--r-- | extensions/source/bibliography/datman.cxx | 2 | ||||
-rw-r--r-- | extensions/source/plugin/aqua/sysplug.mm | 4 | ||||
-rw-r--r-- | extensions/source/plugin/inc/plugin/impl.hxx | 9 | ||||
-rw-r--r-- | extensions/source/plugin/unx/sysplug.cxx | 4 | ||||
-rw-r--r-- | extensions/source/plugin/win/sysplug.cxx | 4 | ||||
-rw-r--r-- | extensions/source/propctrlr/browserlistbox.hxx | 4 | ||||
-rw-r--r-- | extensions/source/propctrlr/browserview.cxx | 2 | ||||
-rw-r--r-- | extensions/source/propctrlr/standardcontrol.cxx | 2 | ||||
-rw-r--r-- | extensions/source/resource/ResourceIndexAccess.cxx | 14 | ||||
-rw-r--r-- | extensions/source/resource/ResourceIndexAccess.hxx | 4 | ||||
-rw-r--r-- | extensions/source/resource/oooresourceloader.cxx | 4 | ||||
-rw-r--r-- | extensions/source/scanner/scanunx.cxx | 20 | ||||
-rw-r--r-- | extensions/source/update/check/updatecheckjob.cxx | 4 |
13 files changed, 37 insertions, 40 deletions
diff --git a/extensions/source/bibliography/datman.cxx b/extensions/source/bibliography/datman.cxx index fcc7598a36e8..961be409d860 100644 --- a/extensions/source/bibliography/datman.cxx +++ b/extensions/source/bibliography/datman.cxx @@ -71,7 +71,7 @@ #include "bib.hrc" #include "bibliography.hrc" #include <connectivity/dbtools.hxx> -#include <boost/scoped_ptr.hpp> +#include <memory> using namespace ::com::sun::star; using namespace ::com::sun::star::beans; diff --git a/extensions/source/plugin/aqua/sysplug.mm b/extensions/source/plugin/aqua/sysplug.mm index ad6210026851..56ce65067537 100644 --- a/extensions/source/plugin/aqua/sysplug.mm +++ b/extensions/source/plugin/aqua/sysplug.mm @@ -75,9 +75,9 @@ struct SysPlugData } }; -::boost::shared_ptr<SysPlugData> CreateSysPlugData() +std::shared_ptr<SysPlugData> CreateSysPlugData() { - return ::boost::shared_ptr<SysPlugData>(new SysPlugData); + return std::shared_ptr<SysPlugData>(new SysPlugData); } void XPlugin_Impl::SetSysPlugDataParentView(SystemEnvData const& rEnvData) diff --git a/extensions/source/plugin/inc/plugin/impl.hxx b/extensions/source/plugin/inc/plugin/impl.hxx index e0e9487926a9..8de11bdea6bd 100644 --- a/extensions/source/plugin/inc/plugin/impl.hxx +++ b/extensions/source/plugin/inc/plugin/impl.hxx @@ -30,11 +30,8 @@ #include <config_lgpl.h> -#ifdef SOLARIS #include <limits> -#endif - -#include <boost/shared_ptr.hpp> +#include <memory> #include "cppuhelper/weak.hxx" @@ -83,7 +80,7 @@ struct SysPlugData; -::boost::shared_ptr<SysPlugData> CreateSysPlugData(); +std::shared_ptr<SysPlugData> CreateSysPlugData(); extern "C" { @@ -130,7 +127,7 @@ private: PluginComm* m_pPluginComm; NPP_t m_aInstance; NPWindow m_aNPWindow; - ::boost::shared_ptr<SysPlugData> m_pSysPlugData; + std::shared_ptr<SysPlugData> m_pSysPlugData; rtl_TextEncoding m_aEncoding; const char** m_pArgv; diff --git a/extensions/source/plugin/unx/sysplug.cxx b/extensions/source/plugin/unx/sysplug.cxx index 87b58856b7f3..acb08a37138e 100644 --- a/extensions/source/plugin/unx/sysplug.cxx +++ b/extensions/source/plugin/unx/sysplug.cxx @@ -45,9 +45,9 @@ #include <plugin/impl.hxx> -::boost::shared_ptr<SysPlugData> CreateSysPlugData() +std::shared_ptr<SysPlugData> CreateSysPlugData() { - return ::boost::shared_ptr<SysPlugData>(); + return std::shared_ptr<SysPlugData>(); } UnxPluginComm::UnxPluginComm( diff --git a/extensions/source/plugin/win/sysplug.cxx b/extensions/source/plugin/win/sysplug.cxx index 58d8951b7d7e..305964170b9b 100644 --- a/extensions/source/plugin/win/sysplug.cxx +++ b/extensions/source/plugin/win/sysplug.cxx @@ -65,9 +65,9 @@ void TRACEN( char const * s, long n ); #define TRACEN(x,n) #endif -::boost::shared_ptr<SysPlugData> CreateSysPlugData() +std::shared_ptr<SysPlugData> CreateSysPlugData() { - return ::boost::shared_ptr<SysPlugData>(); + return std::shared_ptr<SysPlugData>(); } diff --git a/extensions/source/propctrlr/browserlistbox.hxx b/extensions/source/propctrlr/browserlistbox.hxx index 72771c52d8de..7683f9c526b1 100644 --- a/extensions/source/propctrlr/browserlistbox.hxx +++ b/extensions/source/propctrlr/browserlistbox.hxx @@ -32,10 +32,10 @@ #include <tools/link.hxx> #include <rtl/ref.hxx> +#include <memory> #include <set> #include <unordered_map> #include <vector> -#include <boost/shared_ptr.hpp> namespace pcr @@ -51,7 +51,7 @@ namespace pcr // administrative structures for OBrowserListBox - typedef ::boost::shared_ptr< OBrowserLine > BrowserLinePointer; + typedef std::shared_ptr< OBrowserLine > BrowserLinePointer; struct ListBoxLine { OUString aName; diff --git a/extensions/source/propctrlr/browserview.cxx b/extensions/source/propctrlr/browserview.cxx index 33d884365fb1..90b622076627 100644 --- a/extensions/source/propctrlr/browserview.cxx +++ b/extensions/source/propctrlr/browserview.cxx @@ -20,8 +20,8 @@ #include "browserview.hxx" #include "propertyeditor.hxx" #include "propctrlr.hrc" -#include <boost/scoped_ptr.hpp> #include <vcl/tabpage.hxx> +#include <memory> namespace pcr { diff --git a/extensions/source/propctrlr/standardcontrol.cxx b/extensions/source/propctrlr/standardcontrol.cxx index c4276e731899..9ffb0daeee66 100644 --- a/extensions/source/propctrlr/standardcontrol.cxx +++ b/extensions/source/propctrlr/standardcontrol.cxx @@ -49,7 +49,7 @@ #include <cstdlib> #include <limits> #include <boost/bind.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> namespace pcr diff --git a/extensions/source/resource/ResourceIndexAccess.cxx b/extensions/source/resource/ResourceIndexAccess.cxx index 9b47ae23fb30..403aaf4b9c99 100644 --- a/extensions/source/resource/ResourceIndexAccess.cxx +++ b/extensions/source/resource/ResourceIndexAccess.cxx @@ -26,21 +26,21 @@ using namespace ::com::sun::star::container; namespace { - static ::boost::shared_ptr<ResMgr> GetResMgr(Sequence<Any> const& rArgs) + static std::shared_ptr<ResMgr> GetResMgr(Sequence<Any> const& rArgs) { if(rArgs.getLength()!=1) - return ::boost::shared_ptr<ResMgr>(); + return std::shared_ptr<ResMgr>(); OUString sFilename; rArgs[0] >>= sFilename; SolarMutexGuard aGuard; const OString sEncName(OUStringToOString(sFilename, osl_getThreadTextEncoding())); - return ::boost::shared_ptr<ResMgr>(ResMgr::CreateResMgr(sEncName.getStr())); + return std::shared_ptr<ResMgr>(ResMgr::CreateResMgr(sEncName.getStr())); } class ResourceIndexAccessBase : public cppu::WeakImplHelper< ::com::sun::star::container::XIndexAccess> { public: - ResourceIndexAccessBase( ::boost::shared_ptr<ResMgr> pResMgr) + ResourceIndexAccessBase( std::shared_ptr<ResMgr> pResMgr) : m_pResMgr(pResMgr) { OSL_ENSURE(m_pResMgr, "no resource manager given"); @@ -55,13 +55,13 @@ namespace protected: // m_pResMgr should never be NULL - const ::boost::shared_ptr<ResMgr> m_pResMgr; + const std::shared_ptr<ResMgr> m_pResMgr; }; class ResourceStringIndexAccess : public ResourceIndexAccessBase { public: - ResourceStringIndexAccess( ::boost::shared_ptr<ResMgr> pResMgr) + ResourceStringIndexAccess( std::shared_ptr<ResMgr> pResMgr) : ResourceIndexAccessBase(pResMgr) {} // XIndexAccess virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( ::sal_Int32 Index ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; @@ -73,7 +73,7 @@ namespace class ResourceStringListIndexAccess : public ResourceIndexAccessBase { public: - ResourceStringListIndexAccess( ::boost::shared_ptr<ResMgr> pResMgr) + ResourceStringListIndexAccess( std::shared_ptr<ResMgr> pResMgr) : ResourceIndexAccessBase(pResMgr) {} // XIndexAccess virtual ::com::sun::star::uno::Any SAL_CALL getByIndex( ::sal_Int32 Index ) throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; diff --git a/extensions/source/resource/ResourceIndexAccess.hxx b/extensions/source/resource/ResourceIndexAccess.hxx index 596c0afd390d..97a6a49c361f 100644 --- a/extensions/source/resource/ResourceIndexAccess.hxx +++ b/extensions/source/resource/ResourceIndexAccess.hxx @@ -11,12 +11,12 @@ #define INCLUDED_EXTENSIONS_SOURCE_RESOURCE_RESOURCEINDEXACCESS_HXX -#include <boost/shared_ptr.hpp> #include <com/sun/star/container/XNameAccess.hpp> #include <com/sun/star/uno/Reference.hxx> #include <com/sun/star/uno/Sequence.hxx> #include <com/sun/star/uno/XInterface.hpp> #include <cppuhelper/implbase.hxx> +#include <memory> namespace com { namespace sun { namespace star { namespace uno { class XComponentContext; @@ -46,7 +46,7 @@ namespace extensions { namespace resource private: // m_pResMgr should never be NULL - const ::boost::shared_ptr<ResMgr> m_pResMgr; + const std::shared_ptr<ResMgr> m_pResMgr; }; }} diff --git a/extensions/source/resource/oooresourceloader.cxx b/extensions/source/resource/oooresourceloader.cxx index edba15919be8..08158fd0f062 100644 --- a/extensions/source/resource/oooresourceloader.cxx +++ b/extensions/source/resource/oooresourceloader.cxx @@ -26,8 +26,8 @@ #include <cppuhelper/implbase.hxx> #include <cppuhelper/weakref.hxx> -#include <boost/shared_ptr.hpp> #include <map> +#include <memory> using namespace ::com::sun::star::uno; using namespace ::com::sun::star::resource; @@ -94,7 +94,7 @@ namespace extensions { namespace resource class OpenOfficeResourceBundle : public OpenOfficeResourceBundle_Base { private: - typedef ::boost::shared_ptr< IResourceType > ResourceTypePtr; + typedef std::shared_ptr< IResourceType > ResourceTypePtr; typedef ::std::map< OUString, ResourceTypePtr > ResourceTypes; ::osl::Mutex m_aMutex; diff --git a/extensions/source/scanner/scanunx.cxx b/extensions/source/scanner/scanunx.cxx index 7d4da1f523fe..297a86d7b058 100644 --- a/extensions/source/scanner/scanunx.cxx +++ b/extensions/source/scanner/scanunx.cxx @@ -21,7 +21,7 @@ #include <sanedlg.hxx> #include <osl/thread.hxx> #include <cppuhelper/queryinterface.hxx> -#include <boost/shared_ptr.hpp> +#include <memory> #if OSL_DEBUG_LEVEL > 1 #include <stdio.h> @@ -110,7 +110,7 @@ struct SaneHolder namespace { - typedef std::vector< boost::shared_ptr<SaneHolder> > sanevec; + typedef std::vector< std::shared_ptr<SaneHolder> > sanevec; class allSanes { private: @@ -146,7 +146,7 @@ namespace class ScannerThread : public osl::Thread { - boost::shared_ptr<SaneHolder> m_pHolder; + std::shared_ptr<SaneHolder> m_pHolder; Reference< com::sun::star::lang::XEventListener > m_xListener; ScannerManager* m_pManager; // just for the disposing call @@ -154,7 +154,7 @@ public: virtual void run() SAL_OVERRIDE; virtual void onTerminated() SAL_OVERRIDE { delete this; } public: - ScannerThread( boost::shared_ptr<SaneHolder> pHolder, + ScannerThread( std::shared_ptr<SaneHolder> pHolder, const Reference< com::sun::star::lang::XEventListener >& listener, ScannerManager* pManager ); virtual ~ScannerThread(); @@ -163,7 +163,7 @@ public: ScannerThread::ScannerThread( - boost::shared_ptr<SaneHolder> pHolder, + std::shared_ptr<SaneHolder> pHolder, const Reference< com::sun::star::lang::XEventListener >& listener, ScannerManager* pManager ) : m_pHolder( pHolder ), m_xListener( listener ), m_pManager( pManager ) @@ -251,7 +251,7 @@ Sequence< ScannerContext > ScannerManager::getAvailableScanners() throw(std::exc if( rSanes.empty() ) { - boost::shared_ptr<SaneHolder> pSaneHolder(new SaneHolder); + std::shared_ptr<SaneHolder> pSaneHolder(new SaneHolder); if( Sane::IsSane() ) rSanes.push_back( pSaneHolder ); } @@ -290,7 +290,7 @@ sal_Bool ScannerManager::configureScannerAndScan( ScannerContext& scanner_contex ScanError_InvalidContext ); - boost::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; + std::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; if( pHolder->m_bBusy ) throw ScannerException( "Scanner is busy", @@ -328,7 +328,7 @@ void ScannerManager::startScan( const ScannerContext& scanner_context, Reference< XScannerManager >( this ), ScanError_InvalidContext ); - boost::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; + std::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; if( pHolder->m_bBusy ) throw ScannerException( "Scanner is busy", @@ -355,7 +355,7 @@ ScanError ScannerManager::getError( const ScannerContext& scanner_context ) thro ScanError_InvalidContext ); - boost::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; + std::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; return pHolder->m_nError; } @@ -373,7 +373,7 @@ Reference< css::awt::XBitmap > ScannerManager::getBitmap( const ScannerContext& Reference< XScannerManager >( this ), ScanError_InvalidContext ); - boost::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; + std::shared_ptr<SaneHolder> pHolder = rSanes[scanner_context.InternalData]; osl::MutexGuard aProtGuard( pHolder->m_aProtector ); diff --git a/extensions/source/update/check/updatecheckjob.cxx b/extensions/source/update/check/updatecheckjob.cxx index e725bb3e0287..3dfefd6a0abc 100644 --- a/extensions/source/update/check/updatecheckjob.cxx +++ b/extensions/source/update/check/updatecheckjob.cxx @@ -24,7 +24,7 @@ #include "updatehdl.hxx" #include "updateprotocol.hxx" -#include <boost/scoped_ptr.hpp> +#include <memory> #include <cppuhelper/implbase.hxx> #include <cppuhelper/implementationentry.hxx> #include <cppuhelper/supportsservice.hxx> @@ -103,7 +103,7 @@ public: private: uno::Reference<uno::XComponentContext> m_xContext; uno::Reference< frame::XDesktop2 > m_xDesktop; - boost::scoped_ptr< InitUpdateCheckJobThread > m_pInitThread; + std::unique_ptr< InitUpdateCheckJobThread > m_pInitThread; void handleExtensionUpdates( const uno::Sequence< beans::NamedValue > &rListProp ); }; |