comphelper/source/misc/configuration.cxx | 17 cui/source/options/certpath.cxx | 2 cui/source/options/fontsubs.cxx | 2 cui/source/options/optbasic.cxx | 4 cui/source/options/optgdlg.cxx | 4 cui/source/options/optmemory.cxx | 6 cui/source/options/optopencl.cxx | 2 cui/source/options/optpath.cxx | 2 cui/source/options/personalization.cxx | 2 desktop/source/app/app.cxx | 6 desktop/source/app/langselect.cxx | 4 desktop/source/app/userinstall.cxx | 2 fpicker/source/office/PlacesListBox.hxx | 4 fpicker/source/office/iodlg.cxx | 2 include/comphelper/configuration.hxx | 22 include/svtools/PlaceEditDialog.hxx | 10 include/toolkit/awt/vclxprinter.hxx | 8 include/vcl/IconThemeScanner.hxx | 5 include/vcl/oldprintadaptor.hxx | 2 include/vcl/print.hxx | 14 include/vcl/settings.hxx | 12 include/vcl/window.hxx | 4 lotuswordpro/source/filter/xfilter/xfstylemanager.cxx | 2 opencl/source/openclconfig.cxx | 2 sc/qa/unit/subsequent_export-test.cxx | 4 sc/source/core/tool/formulagroup.cxx | 4 sc/source/filter/oox/workbookhelper.cxx | 2 sc/source/ui/docshell/docsh.cxx | 2 sc/source/ui/unoobj/docuno.cxx | 6 sd/qa/unit/export-tests.cxx | 4 sd/source/ui/dlg/PhotoAlbumDialog.cxx | 2 sd/source/ui/remotecontrol/Server.cxx | 4 sfx2/source/appl/appbas.cxx | 2 sfx2/source/appl/appcfg.cxx | 2 sfx2/source/dialog/dialoghelper.cxx | 2 sfx2/source/doc/templatedlg.cxx | 8 sfx2/source/view/viewimp.hxx | 4 sfx2/source/view/viewprn.cxx | 40 sfx2/source/view/viewsh.cxx | 12 starmath/source/cfgitem.cxx | 8 svl/source/config/asiancfg.cxx | 2 svtools/qa/unit/GraphicObjectTest.cxx | 2 svtools/source/dialogs/PlaceEditDialog.cxx | 69 - sw/qa/extras/globalfilter/globalfilter.cxx | 6 sw/source/core/doc/docnum.cxx | 12 sw/source/core/doc/textboxhelper.cxx | 9 sw/source/ui/config/optload.cxx | 6 toolkit/source/awt/vclxprinter.cxx | 26 unotools/source/config/saveopt.cxx | 2 vcl/generic/glyphs/gcach_ftyp.cxx | 22 vcl/generic/print/genprnpsp.cxx | 18 vcl/inc/generic/glyphcache.hxx | 10 vcl/inc/impimagetree.hxx | 4 vcl/inc/pch/precompiled_vcl.hxx | 1 vcl/inc/printdlg.hxx | 6 vcl/inc/window.h | 4 vcl/source/app/IconThemeScanner.cxx | 4 vcl/source/app/settings.cxx | 985 ++++++++---------- vcl/source/gdi/impimagetree.cxx | 16 vcl/source/gdi/oldprintadaptor.cxx | 16 vcl/source/gdi/print3.cxx | 321 ++--- vcl/source/outdev/nativecontrols.cxx | 8 vcl/source/window/builder.cxx | 2 vcl/source/window/printdlg.cxx | 10 vcl/source/window/window2.cxx | 2 vcl/unx/generic/gdi/cairotextrender.cxx | 4 66 files changed, 891 insertions(+), 922 deletions(-)
New commits: commit f45c52d0c8fc326b4cb12e1b8f581a60991079ba Author: Caolán McNamara <[email protected]> Date: Fri Feb 6 13:03:37 2015 +0000 coverity#1267635 Logically dead code Change-Id: If2f26bd6414622889fc15d3806851e497882558c diff --git a/sw/source/core/doc/docnum.cxx b/sw/source/core/doc/docnum.cxx index cc1efe0..1618e0b 100644 --- a/sw/source/core/doc/docnum.cxx +++ b/sw/source/core/doc/docnum.cxx @@ -762,8 +762,7 @@ bool SwDoc::GotoOutline( SwPosition& rPos, const OUString& rName ) const static void lcl_ChgNumRule( SwDoc& rDoc, const SwNumRule& rRule ) { SwNumRule* pOld = rDoc.FindNumRulePtr( rRule.GetName() ); - assert(pOld); //we cannot proceed without the old NumRule - if (!pOld) + if (!pOld) //we cannot proceed without the old NumRule return; sal_uInt16 nChgFmtLevel = 0; @@ -855,12 +854,12 @@ void SwDoc::SetNumRule( const SwPaM& rPam, else if ( rRule != *pNewOrChangedNumRule ) { // change existing numbering rule - if( pUndo != NULL ) + if (pUndo) { pUndo->SaveOldNumRule( *pNewOrChangedNumRule ); } ::lcl_ChgNumRule( *this, rRule ); - if( pUndo != NULL ) + if (pUndo) { pUndo->SetLRSpaceEndPos(); } @@ -1060,9 +1059,10 @@ void SwDoc::ChgNumRuleFmts( const SwNumRule& rRule ) GetIDocumentUndoRedo().AppendUndo( pUndo ); } ::lcl_ChgNumRule( *this, rRule ); - - if( pUndo ) + if (pUndo) + { pUndo->SetLRSpaceEndPos(); + } getIDocumentState().SetModified(); } commit 233930159fa9bd18af81b9c5c358123d790cb5e9 Author: Caolán McNamara <[email protected]> Date: Fri Feb 6 12:55:41 2015 +0000 coverity#1267636 Logically dead code Change-Id: I3bd06dee1a5536552f79d9eddf5c7059723cba2e diff --git a/sw/source/core/doc/textboxhelper.cxx b/sw/source/core/doc/textboxhelper.cxx index f5096a0..28471b48 100644 --- a/sw/source/core/doc/textboxhelper.cxx +++ b/sw/source/core/doc/textboxhelper.cxx @@ -222,7 +222,7 @@ sal_Int32 SwTextBoxHelper::getCount(SdrPage* pPage, std::set<const SwFrmFmt*>& r uno::Any SwTextBoxHelper::getByIndex(SdrPage* pPage, sal_Int32 nIndex, std::set<const SwFrmFmt*>& rTextBoxes) throw(lang::IndexOutOfBoundsException) { - if (nIndex < 0 || nIndex >= getCount(pPage, rTextBoxes)) + if (nIndex < 0) throw lang::IndexOutOfBoundsException(); SdrObject* pRet = 0; @@ -238,8 +238,11 @@ uno::Any SwTextBoxHelper::getByIndex(SdrPage* pPage, sal_Int32 nIndex, std::set< } ++nCount; } - assert(pRet); - return pRet ? uno::makeAny(uno::Reference<drawing::XShape>(pRet->getUnoShape(), uno::UNO_QUERY)) : uno::Any(); + + if (!pRet) + throw lang::IndexOutOfBoundsException(); + + return uno::makeAny(uno::Reference<drawing::XShape>(pRet->getUnoShape(), uno::UNO_QUERY)); } sal_Int32 SwTextBoxHelper::getOrdNum(const SdrObject* pObject, std::set<const SwFrmFmt*>& rTextBoxes) commit 9e90c4d72e414c9bff86fad8a87c7f584486a08d Author: Caolán McNamara <[email protected]> Date: Fri Feb 6 12:52:02 2015 +0000 coverity#1267644 Logically dead code Change-Id: Ida19552cd9163507bea36a189811fdf8c152cae6 diff --git a/starmath/source/cfgitem.cxx b/starmath/source/cfgitem.cxx index dfb2a09..8092dd8 100644 --- a/starmath/source/cfgitem.cxx +++ b/starmath/source/cfgitem.cxx @@ -694,12 +694,10 @@ void SmMathConfig::SaveFontFormatList() OUString aDelim( "/" ); for (size_t i = 0; i < nCount; ++i) { - OUString aFntFmtId( rFntFmtList.GetFontFormatId( i ) ); - const SmFontFormat *pFntFmt = rFntFmtList.GetFontFormat( aFntFmtId ); + OUString aFntFmtId(rFntFmtList.GetFontFormatId(i)); + const SmFontFormat *pFntFmt = rFntFmtList.GetFontFormat(i); assert(pFntFmt); - if (!pFntFmt) - continue; - const SmFontFormat aFntFmt( *pFntFmt ); + const SmFontFormat aFntFmt(*pFntFmt); OUString aNodeNameDelim( FONT_FORMAT_LIST ); aNodeNameDelim += aDelim; commit 03f52fb64ce489ba4bf48fa18cebcdf24805480b Author: Caolán McNamara <[email protected]> Date: Fri Feb 6 12:28:33 2015 +0000 coverity#1267642 Logically dead code reviewed the 120+ callers and confirmed it is never NULL Change-Id: I5c029dc35b265d9e11a0a222170dad4d6a55ed2f diff --git a/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx b/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx index c5857988..6a31a9c 100644 --- a/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx +++ b/lotuswordpro/source/filter/xfilter/xfstylemanager.cxx @@ -116,8 +116,6 @@ IXFStyleRet XFStyleManager::AddStyle(IXFStyle *pStyle) assert(pStyle); OUString name; - if( !pStyle ) - return aRet; name = pStyle->GetStyleName(); if( pStyle->GetStyleFamily() == enumXFStyleText ) commit c7258cfccdf9f4c5235da1b135801f957a5b0ec1 Author: Caolán McNamara <[email protected]> Date: Fri Feb 6 09:46:57 2015 +0000 shared_ptr<T>(new T(args)) -> make_shared<T>(args) and boost:make_shared->std::make_shared Change-Id: Ic1e187c52c856a7b27817967b2caa8920f23a98d diff --git a/comphelper/source/misc/configuration.cxx b/comphelper/source/misc/configuration.cxx index 29970ff..7468c55 100644 --- a/comphelper/source/misc/configuration.cxx +++ b/comphelper/source/misc/configuration.cxx @@ -10,8 +10,8 @@ #include <sal/config.h> #include <cassert> +#include <memory> -#include <boost/shared_ptr.hpp> #include <com/sun/star/configuration/ReadOnlyAccess.hpp> #include <com/sun/star/configuration/ReadWriteAccess.hpp> #include <com/sun/star/configuration/XReadWriteAccess.hpp> @@ -66,14 +66,13 @@ OUString extendLocalizedPath(OUString const & path, OUString const & locale) { } -boost::shared_ptr< comphelper::ConfigurationChanges > +std::shared_ptr< comphelper::ConfigurationChanges > comphelper::ConfigurationChanges::create( css::uno::Reference< css::uno::XComponentContext > const & context) { return TheConfigurationWrapper::get(context).createChanges(); } - comphelper::ConfigurationChanges::~ConfigurationChanges() {} void comphelper::ConfigurationChanges::commit() const { @@ -129,7 +128,7 @@ css::uno::Any comphelper::detail::ConfigurationWrapper::getPropertyValue( } void comphelper::detail::ConfigurationWrapper::setPropertyValue( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path, com::sun::star::uno::Any const & value) const { assert(batch.get() != 0); @@ -145,7 +144,7 @@ comphelper::detail::ConfigurationWrapper::getLocalizedPropertyValue( } void comphelper::detail::ConfigurationWrapper::setLocalizedPropertyValue( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path, com::sun::star::uno::Any const & value) const { assert(batch.get() != 0); @@ -165,7 +164,7 @@ comphelper::detail::ConfigurationWrapper::getGroupReadOnly( css::uno::Reference< css::container::XHierarchicalNameReplace > comphelper::detail::ConfigurationWrapper::getGroupReadWrite( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path) const { assert(batch.get() != 0); @@ -185,16 +184,16 @@ comphelper::detail::ConfigurationWrapper::getSetReadOnly( css::uno::Reference< css::container::XNameContainer > comphelper::detail::ConfigurationWrapper::getSetReadWrite( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path) const { assert(batch.get() != 0); return batch->getSet(path); } -boost::shared_ptr< comphelper::ConfigurationChanges > +std::shared_ptr< comphelper::ConfigurationChanges > comphelper::detail::ConfigurationWrapper::createChanges() const { - return boost::shared_ptr< ConfigurationChanges >( + return std::shared_ptr< ConfigurationChanges >( new ConfigurationChanges(context_)); } diff --git a/cui/source/options/certpath.cxx b/cui/source/options/certpath.cxx index a31c252..d6345be 100644 --- a/cui/source/options/certpath.cxx +++ b/cui/source/options/certpath.cxx @@ -119,7 +119,7 @@ IMPL_LINK_NOARG(CertPathDialog, OKHdl_Impl) { try { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Security::Scripting::CertDir::set( getDirectory(), batch); diff --git a/cui/source/options/fontsubs.cxx b/cui/source/options/fontsubs.cxx index a0e92f9..5dab12a 100644 --- a/cui/source/options/fontsubs.cxx +++ b/cui/source/options/fontsubs.cxx @@ -170,7 +170,7 @@ bool SvxFontSubstTabPage::FillItemSet( SfxItemSet* ) if(pConfig->IsModified()) pConfig->Commit(); pConfig->Apply(); - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); if(m_pFontHeightLB->IsValueChangedFromSaved()) officecfg::Office::Common::Font::SourceViewFont::FontHeight::set( diff --git a/cui/source/options/optbasic.cxx b/cui/source/options/optbasic.cxx index db24702..2c5498e 100644 --- a/cui/source/options/optbasic.cxx +++ b/cui/source/options/optbasic.cxx @@ -69,7 +69,7 @@ void SvxBasicIDEOptionsPage::LoadConfig() bool SvxBasicIDEOptionsPage::FillItemSet( SfxItemSet* /*rCoreSet*/ ) { bool bModified = false; - boost::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); if( pAutocloseProcChk->IsValueChangedFromSaved() ) { @@ -80,7 +80,7 @@ bool SvxBasicIDEOptionsPage::FillItemSet( SfxItemSet* /*rCoreSet*/ ) if( pCodeCompleteChk->IsValueChangedFromSaved() ) { - //boost::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); + //std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); officecfg::Office::BasicIDE::Autocomplete::CodeComplete::set( pCodeCompleteChk->IsChecked(), batch ); CodeCompleteOptions::SetCodeCompleteOn( pCodeCompleteChk->IsChecked() ); bModified = true; diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx index cc82f28..512e8ad 100644 --- a/cui/source/options/optgdlg.cxx +++ b/cui/source/options/optgdlg.cxx @@ -143,7 +143,7 @@ OpenGLCfg::~OpenGLCfg() { if (mbModified) { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::VCL::UseOpenGL::set(mbUseOpenGL, batch); officecfg::Office::Common::VCL::ForceOpenGL::set(mbForceOpenGL, batch); batch->commit(); @@ -318,7 +318,7 @@ SfxTabPage* OfaMiscTabPage::Create( vcl::Window* pParent, const SfxItemSet* rAtt bool OfaMiscTabPage::FillItemSet( SfxItemSet* rSet ) { bool bModified = false; - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); SvtHelpOptions aHelpOptions; if ( m_pToolTipsCB->IsValueChangedFromSaved() ) diff --git a/cui/source/options/optmemory.cxx b/cui/source/options/optmemory.cxx index 2faa4ea..ea3cdd8 100644 --- a/cui/source/options/optmemory.cxx +++ b/cui/source/options/optmemory.cxx @@ -147,20 +147,16 @@ OfaMemoryOptionsPage::~OfaMemoryOptionsPage() { } - - SfxTabPage* OfaMemoryOptionsPage::Create( vcl::Window* pParent, const SfxItemSet* rAttrSet ) { return new OfaMemoryOptionsPage( pParent, *rAttrSet ); } - - bool OfaMemoryOptionsPage::FillItemSet( SfxItemSet* rSet ) { bool bModified = false; - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); if ( m_pUndoEdit->IsValueChangedFromSaved() ) diff --git a/cui/source/options/optopencl.cxx b/cui/source/options/optopencl.cxx index 63475ea..cbc8a38 100644 --- a/cui/source/options/optopencl.cxx +++ b/cui/source/options/optopencl.cxx @@ -121,7 +121,7 @@ SfxTabPage* SvxOpenCLTabPage::Create( vcl::Window* pParent, const SfxItemSet* rA bool SvxOpenCLTabPage::FillItemSet( SfxItemSet* ) { bool bModified = false; - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); if (mpUseOpenCL->IsValueChangedFromSaved()) maConfig.mbUseOpenCL = mpUseOpenCL->IsChecked(); diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx index 9ecb252..a92f7896 100644 --- a/cui/source/options/optpath.cxx +++ b/cui/source/options/optpath.cxx @@ -517,7 +517,7 @@ void SvxPathTabPage::ChangeCurrentEntry( const OUString& _rFolder ) // Set configuration flag to notify file picker that it's necessary // to take over the path provided. - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Path::Info::WorkPathChanged::set( true, batch); diff --git a/cui/source/options/personalization.cxx b/cui/source/options/personalization.cxx index dbc1463..1bf0132 100644 --- a/cui/source/options/personalization.cxx +++ b/cui/source/options/personalization.cxx @@ -319,7 +319,7 @@ bool SvxPersonalizationTabPage::FillItemSet( SfxItemSet * ) } // write - boost::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); if( aPersona == "no" ) m_aPersonaSettings.clear(); officecfg::Office::Common::Misc::Persona::set( aPersona, batch ); diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx index 562b1f2..59d984d 100644 --- a/desktop/source/app/app.cxx +++ b/desktop/source/app/app.cxx @@ -291,7 +291,7 @@ bool shouldLaunchQuickstart() void SetRestartState() { try { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Setup::Office::OfficeRestartInProgress::set(true, batch); batch->commit(); @@ -304,7 +304,7 @@ void DoRestartActionsIfNecessary(bool quickstart) { if (quickstart) { try { if (officecfg::Setup::Office::OfficeRestartInProgress::get()) { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Setup::Office::OfficeRestartInProgress::set( false, batch); @@ -2848,7 +2848,7 @@ void Desktop::CheckFirstRun( ) } #endif - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Misc::FirstRun::set(false, batch); batch->commit(); diff --git a/desktop/source/app/langselect.cxx b/desktop/source/app/langselect.cxx index c853c60..a3f9479 100644 --- a/desktop/source/app/langselect.cxx +++ b/desktop/source/app/langselect.cxx @@ -141,7 +141,7 @@ bool prepareLocale() { if (locale.isEmpty()) { // Selected language is not/no longer installed: try { - boost::shared_ptr<comphelper::ConfigurationChanges> batch( + std::shared_ptr<comphelper::ConfigurationChanges> batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Linguistic::General::UILocale::set( "", batch); @@ -184,7 +184,7 @@ bool prepareLocale() { css::uno::UNO_QUERY_THROW)->setLocale(tag.getLocale(false)); if (!cmdLanguage) { try { - boost::shared_ptr<comphelper::ConfigurationChanges> batch( + std::shared_ptr<comphelper::ConfigurationChanges> batch( comphelper::ConfigurationChanges::create()); officecfg::Setup::L10N::ooLocale::set(locale, batch); batch->commit(); diff --git a/desktop/source/app/userinstall.cxx b/desktop/source/app/userinstall.cxx index ef0b0a1..3cb4d39 100644 --- a/desktop/source/app/userinstall.cxx +++ b/desktop/source/app/userinstall.cxx @@ -130,7 +130,7 @@ Status create(OUString const & uri) { return ERROR_OTHER; } #endif - boost::shared_ptr<comphelper::ConfigurationChanges> batch( + std::shared_ptr<comphelper::ConfigurationChanges> batch( comphelper::ConfigurationChanges::create()); officecfg::Setup::Office::ooSetupInstCompleted::set(true, batch); batch->commit(); diff --git a/fpicker/source/office/PlacesListBox.hxx b/fpicker/source/office/PlacesListBox.hxx index 4dd95a4..8fa24be 100644 --- a/fpicker/source/office/PlacesListBox.hxx +++ b/fpicker/source/office/PlacesListBox.hxx @@ -11,13 +11,13 @@ #include <iodlg.hxx> -#include <boost/shared_ptr.hpp> #include <svtools/place.hxx> #include <svtools/svtabbx.hxx> +#include <memory> #include <vector> -typedef boost::shared_ptr< Place > PlacePtr; +typedef std::shared_ptr< Place > PlacePtr; class PlacesListBox; class PlacesListBox_Impl : public SvHeaderTabListBox diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx index e706f0b..370b2e7 100644 --- a/fpicker/source/office/iodlg.cxx +++ b/fpicker/source/office/iodlg.cxx @@ -430,7 +430,7 @@ SvtFileDialog::~SvtFileDialog() } } - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create(m_context)); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create(m_context)); officecfg::Office::Common::Misc::FilePickerPlacesUrls::set(placesUrlsList, batch, m_context); officecfg::Office::Common::Misc::FilePickerPlacesNames::set(placesNamesList, batch, m_context); batch->commit(); diff --git a/include/comphelper/configuration.hxx b/include/comphelper/configuration.hxx index 9be907c..74ed032 100644 --- a/include/comphelper/configuration.hxx +++ b/include/comphelper/configuration.hxx @@ -14,12 +14,12 @@ #include <boost/noncopyable.hpp> #include <boost/optional.hpp> -#include <boost/shared_ptr.hpp> #include <com/sun/star/uno/Any.hxx> #include <com/sun/star/uno/Reference.hxx> #include <comphelper/comphelperdllapi.h> #include <comphelper/processfactory.hxx> #include <sal/types.h> +#include <memory> namespace com { namespace sun { namespace star { namespace configuration { class XReadWriteAccess; } @@ -45,7 +45,7 @@ namespace detail { class ConfigurationWrapper; } /// directly. class COMPHELPER_DLLPUBLIC ConfigurationChanges: private boost::noncopyable { public: - static boost::shared_ptr< ConfigurationChanges > create( + static std::shared_ptr<ConfigurationChanges> create( com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > const & context = comphelper::getProcessComponentContext()); @@ -94,7 +94,7 @@ public: com::sun::star::uno::Any getPropertyValue(OUString const & path) const; void setPropertyValue( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path, com::sun::star::uno::Any const & value) const; @@ -102,7 +102,7 @@ public: OUString const & path) const; void setLocalizedPropertyValue( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path, com::sun::star::uno::Any const & value) const; @@ -113,7 +113,7 @@ public: com::sun::star::uno::Reference< com::sun::star::container::XHierarchicalNameReplace > getGroupReadWrite( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path) const; com::sun::star::uno::Reference< com::sun::star::container::XNameAccess > @@ -121,10 +121,10 @@ public: com::sun::star::uno::Reference< com::sun::star::container::XNameContainer > getSetReadWrite( - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, OUString const & path) const; - boost::shared_ptr< ConfigurationChanges > createChanges() const; + std::shared_ptr< ConfigurationChanges > createChanges() const; private: com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > @@ -199,7 +199,7 @@ template< typename T, typename U > struct ConfigurationProperty: /// For nillable properties, U is of type boost::optional<U'>. static void set( U const & value, - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > const & context = comphelper::getProcessComponentContext()) { @@ -245,7 +245,7 @@ template< typename T, typename U > struct ConfigurationLocalizedProperty: /// For nillable properties, U is of type boost::optional<U'>. static void set( U const & value, - boost::shared_ptr< ConfigurationChanges > const & batch, + std::shared_ptr< ConfigurationChanges > const & batch, com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > const & context = comphelper::getProcessComponentContext()) { @@ -278,7 +278,7 @@ template< typename T > struct ConfigurationGroup: private boost::noncopyable { /// modifications via the given changes batch. static com::sun::star::uno::Reference< com::sun::star::container::XHierarchicalNameReplace > - get(boost::shared_ptr< ConfigurationChanges > const & batch, + get(std::shared_ptr< ConfigurationChanges > const & batch, com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > const & context = comphelper::getProcessComponentContext()) { @@ -311,7 +311,7 @@ template< typename T > struct ConfigurationSet: private boost::noncopyable { /// modifications via the given changes batch. static com::sun::star::uno::Reference< com::sun::star::container::XNameContainer > - get(boost::shared_ptr< ConfigurationChanges > const & batch, + get(std::shared_ptr< ConfigurationChanges > const & batch, com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext > const & context = comphelper::getProcessComponentContext()) { diff --git a/include/svtools/PlaceEditDialog.hxx b/include/svtools/PlaceEditDialog.hxx index 7990542..5cdad02 100644 --- a/include/svtools/PlaceEditDialog.hxx +++ b/include/svtools/PlaceEditDialog.hxx @@ -21,7 +21,7 @@ #include <svtools/inettbc.hxx> #include <svtools/place.hxx> -#include <boost/shared_ptr.hpp> +#include <memory> #include <vector> class SVT_DLLPUBLIC PlaceEditDialog : public ModalDialog @@ -30,7 +30,7 @@ private : Edit* m_pEDServerName; ListBox* m_pLBServerType; - boost::shared_ptr< DetailsContainer > m_pCurrentDetails; + std::shared_ptr< DetailsContainer > m_xCurrentDetails; Edit* m_pEDUsername; OKButton* m_pBTOk; @@ -44,16 +44,16 @@ private : the m_aDetailsContainer[0] will be shown for the type corresponding to entry 0 in the listbox. */ - std::vector< boost::shared_ptr< DetailsContainer > > m_aDetailsContainers; + std::vector< std::shared_ptr< DetailsContainer > > m_aDetailsContainers; public : PlaceEditDialog( vcl::Window* pParent); - PlaceEditDialog(vcl::Window* pParent, const boost::shared_ptr<Place> &pPlace ); + PlaceEditDialog(vcl::Window* pParent, const std::shared_ptr<Place> &rPlace ); virtual ~PlaceEditDialog(); // Returns a place instance with given information - boost::shared_ptr<Place> GetPlace(); + std::shared_ptr<Place> GetPlace(); OUString GetServerName() { return m_pEDServerName->GetText(); } OUString GetServerUrl(); diff --git a/include/toolkit/awt/vclxprinter.hxx b/include/toolkit/awt/vclxprinter.hxx index 434c47a..71289fe 100644 --- a/include/toolkit/awt/vclxprinter.hxx +++ b/include/toolkit/awt/vclxprinter.hxx @@ -56,7 +56,7 @@ class VCLXPrinterPropertySet :public VCLXPrinterPropertySet_Base ,public ::cppu::OPropertySetHelper { protected: - boost::shared_ptr<Printer> mpPrinter; + std::shared_ptr<Printer> mxPrinter; ::com::sun::star::uno::Reference< ::com::sun::star::awt::XDevice > mxPrnDevice; sal_Int16 mnOrientation; @@ -65,7 +65,7 @@ public: VCLXPrinterPropertySet( const OUString& rPrinterName ); virtual ~VCLXPrinterPropertySet(); - Printer* GetPrinter() const { return mpPrinter.get(); } + Printer* GetPrinter() const { return mxPrinter.get(); } ::com::sun::star::uno::Reference< ::com::sun::star::awt::XDevice > GetDevice(); // ::com::sun::star::uno::XInterface @@ -107,8 +107,8 @@ typedef ::cppu::ImplInheritanceHelper1 < VCLXPrinterPropertySet > VCLXPrinter_Base; class VCLXPrinter: public VCLXPrinter_Base { - boost::shared_ptr<vcl::OldStylePrintAdaptor> mpListener; - JobSetup maInitJobSetup; + std::shared_ptr<vcl::OldStylePrintAdaptor> mxListener; + JobSetup maInitJobSetup; public: VCLXPrinter( const OUString& rPrinterName ); virtual ~VCLXPrinter(); diff --git a/include/vcl/IconThemeScanner.hxx b/include/vcl/IconThemeScanner.hxx index f865490..028173e 100644 --- a/include/vcl/IconThemeScanner.hxx +++ b/include/vcl/IconThemeScanner.hxx @@ -15,7 +15,7 @@ #include <rtl/ustring.hxx> -#include <boost/shared_ptr.hpp> +#include <memory> #include <vector> // forward declaration of unit test class. Required for friend relationship. @@ -39,8 +39,7 @@ public: /** Factory method to create the object. * Provide a path to search for IconThemes. */ - static boost::shared_ptr<IconThemeScanner> - Create(const OUString &path); + static std::shared_ptr<IconThemeScanner> Create(const OUString &path); /** This method will return the standard path where icon themes are located. */ diff --git a/include/vcl/oldprintadaptor.hxx b/include/vcl/oldprintadaptor.hxx index fe71548..72d1163 100644 --- a/include/vcl/oldprintadaptor.hxx +++ b/include/vcl/oldprintadaptor.hxx @@ -29,7 +29,7 @@ namespace vcl { ImplOldStyleAdaptorData* mpData; public: - OldStylePrintAdaptor( const boost::shared_ptr< Printer >& ); + OldStylePrintAdaptor(const std::shared_ptr<Printer>&); virtual ~OldStylePrintAdaptor(); void StartPage(); diff --git a/include/vcl/print.hxx b/include/vcl/print.hxx index d6cfc2d..45226f0 100644 --- a/include/vcl/print.hxx +++ b/include/vcl/print.hxx @@ -35,7 +35,7 @@ #include <com/sun/star/beans/PropertyValue.hpp> #include <com/sun/star/view/PrintableState.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> #include <set> #include <unordered_map> @@ -238,7 +238,7 @@ private: SAL_DLLPRIVATE void ImplUpdateFontList(); SAL_DLLPRIVATE void ImplFindPaperFormatForUserSize( JobSetup&, bool bMatchNearest ); - SAL_DLLPRIVATE bool StartJob( const OUString& rJobName, boost::shared_ptr<vcl::PrinterController>& ); + SAL_DLLPRIVATE bool StartJob( const OUString& rJobName, std::shared_ptr<vcl::PrinterController>& ); static SAL_DLLPRIVATE sal_uLong ImplSalPrinterErrorCodeToVCL( sal_uLong nError ); @@ -386,7 +386,7 @@ public: starts a print job asynchronously (that is will return */ - static void PrintJob( const boost::shared_ptr<vcl::PrinterController>& i_pController, + static void PrintJob( const std::shared_ptr<vcl::PrinterController>& i_pController, const JobSetup& i_rInitSetup ); virtual bool HasMirroredGraphics() const SAL_OVERRIDE; @@ -407,7 +407,7 @@ public: // implementation detail of PrintJob being asynchronous // not exported, not usable outside vcl - static void SAL_DLLPRIVATE ImplPrintJob( const boost::shared_ptr<vcl::PrinterController>& i_pController, + static void SAL_DLLPRIVATE ImplPrintJob( const std::shared_ptr<vcl::PrinterController>& i_pController, const JobSetup& i_rInitSetup ); }; @@ -419,7 +419,7 @@ class VCL_DLLPUBLIC PrinterController { ImplPrinterControllerData* mpImplData; protected: - PrinterController( const boost::shared_ptr<Printer>& ); + PrinterController( const std::shared_ptr<Printer>& ); public: enum NupOrderType { LRTB, TBLR, TBRL, RLTB }; @@ -462,7 +462,7 @@ public: virtual ~PrinterController(); - const boost::shared_ptr<Printer>& getPrinter() const; + const std::shared_ptr<Printer>& getPrinter() const; /* for implementations: get current job properties as changed by e.g. print dialog this gets the current set of properties initially told to Printer::PrintJob @@ -543,7 +543,7 @@ public: SAL_DLLPRIVATE PageSize getPageFile( int i_inUnfilteredPage, GDIMetaFile& rMtf, bool i_bMayUseCache = false ); VCL_PLUGIN_PUBLIC PageSize getFilteredPageFile( int i_nFilteredPage, GDIMetaFile& o_rMtf, bool i_bMayUseCache = false ); VCL_PLUGIN_PUBLIC void printFilteredPage( int i_nPage ); - SAL_DLLPRIVATE void setPrinter( const boost::shared_ptr<Printer>& ); + SAL_DLLPRIVATE void setPrinter( const std::shared_ptr<Printer>& ); SAL_DLLPRIVATE void setOptionChangeHdl( const Link& ); VCL_PLUGIN_PUBLIC void createProgressDialog(); VCL_PLUGIN_PUBLIC bool isProgressCanceled() const; diff --git a/include/vcl/settings.hxx b/include/vcl/settings.hxx index c701654..204a05d 100644 --- a/include/vcl/settings.hxx +++ b/include/vcl/settings.hxx @@ -32,7 +32,7 @@ #include <o3tl/typed_flags_set.hxx> #include <boost/optional.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> class CollatorWrapper; class LocaleDataWrapper; @@ -70,7 +70,7 @@ class VCL_DLLPUBLIC MouseSettings { private: void CopyData(); - boost::shared_ptr<ImplMouseData> mpData; + std::shared_ptr<ImplMouseData> mxData; public: MouseSettings(); @@ -201,7 +201,7 @@ class VCL_DLLPUBLIC StyleSettings void CopyData(); private: - boost::shared_ptr<ImplStyleData> mpData; + std::shared_ptr<ImplStyleData> mxData; public: StyleSettings(); @@ -573,7 +573,7 @@ class VCL_DLLPUBLIC MiscSettings void CopyData(); private: - boost::shared_ptr<ImplMiscData> mpData; + std::shared_ptr<ImplMiscData> mxData; public: MiscSettings(); @@ -598,7 +598,7 @@ public: class VCL_DLLPUBLIC HelpSettings { void CopyData(); - boost::shared_ptr<ImplHelpData> mpData; + std::shared_ptr<ImplHelpData> mxData; public: HelpSettings(); @@ -632,7 +632,7 @@ class VCL_DLLPUBLIC AllSettings private: void CopyData(); - boost::shared_ptr<ImplAllSettingsData> mpData; + std::shared_ptr<ImplAllSettingsData> mxData; public: AllSettings(); diff --git a/include/vcl/window.hxx b/include/vcl/window.hxx index e9c272d..b329f45 100644 --- a/include/vcl/window.hxx +++ b/include/vcl/window.hxx @@ -39,7 +39,7 @@ #include <rtl/ref.hxx> #include <cppuhelper/weakref.hxx> #include <com/sun/star/uno/Reference.hxx> -#include <boost/shared_ptr.hpp> +#include <memory> class VirtualDevice; struct ImplDelData; @@ -1396,7 +1396,7 @@ public: * Adds this widget to the xGroup VclSizeGroup * */ - void add_to_size_group(boost::shared_ptr< VclSizeGroup > xGroup); + void add_to_size_group(std::shared_ptr<VclSizeGroup> xGroup); void remove_from_all_size_groups(); /* diff --git a/opencl/source/openclconfig.cxx b/opencl/source/openclconfig.cxx index 2562b0d..085a33e 100644 --- a/opencl/source/openclconfig.cxx +++ b/opencl/source/openclconfig.cxx @@ -187,7 +187,7 @@ OpenCLConfig OpenCLConfig::get() void OpenCLConfig::set() { - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Misc::UseOpenCL::set(mbUseOpenCL, batch); officecfg::Office::Common::Misc::OpenCLBlackList::set(SetOfImplMatcherToStringSequence(maBlackList), batch); diff --git a/sc/qa/unit/subsequent_export-test.cxx b/sc/qa/unit/subsequent_export-test.cxx index 57ff3b2..4a1b599 100644 --- a/sc/qa/unit/subsequent_export-test.cxx +++ b/sc/qa/unit/subsequent_export-test.cxx @@ -2280,7 +2280,7 @@ void ScExportTest::testSwappedOutImageExport() }; // Set cache size to a very small value to make sure one of the images is swapped out - boost::shared_ptr< comphelper::ConfigurationChanges > xBatch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > xBatch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), xBatch); xBatch->commit(); @@ -2431,7 +2431,7 @@ void ScExportTest::testImageWithSpecialID() }; // Trigger swap out mechanism to test swapped state factor too. - boost::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), batch); batch->commit(); diff --git a/sc/source/core/tool/formulagroup.cxx b/sc/source/core/tool/formulagroup.cxx index 25685e8..306a3ea 100644 --- a/sc/source/core/tool/formulagroup.cxx +++ b/sc/source/core/tool/formulagroup.cxx @@ -26,8 +26,6 @@ #endif #include <rtl/bootstrap.hxx> -#include <boost/scoped_array.hpp> - #include <cstdio> #include <unordered_map> #include <vector> @@ -549,7 +547,7 @@ void FormulaGroupInterpreter::getOpenCLDeviceInfo(sal_Int32& rDeviceId, sal_Int3 void FormulaGroupInterpreter::enableOpenCL_UnitTestsOnly() { - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Misc::UseOpenCL::set(true, batch); batch->commit(); diff --git a/sc/source/filter/oox/workbookhelper.cxx b/sc/source/filter/oox/workbookhelper.cxx index 0dc581b..71e94c8 100644 --- a/sc/source/filter/oox/workbookhelper.cxx +++ b/sc/source/filter/oox/workbookhelper.cxx @@ -673,7 +673,7 @@ void WorkbookGlobals::recalcFormulaCells() if (aBox.GetCheckBoxState()) { // Always perform selected action in the future. - boost::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Calc::Formula::Load::OOXMLRecalcMode::set(sal_Int32(0), batch); ScFormulaOptions aOpt = SC_MOD()->GetFormulaOptions(); aOpt.SetOOXMLRecalcOptions(bHardRecalc ? RECALC_ALWAYS : RECALC_NEVER); diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx index 67b5d5d..29b03c3 100644 --- a/sc/source/ui/docshell/docsh.cxx +++ b/sc/source/ui/docshell/docsh.cxx @@ -482,7 +482,7 @@ bool ScDocShell::LoadXML( SfxMedium* pLoadMedium, const ::com::sun::star::uno::R if (aBox.GetCheckBoxState()) { // Always perform selected action in the future. - boost::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create() ); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Calc::Formula::Load::ODFRecalcMode::set(sal_Int32(0), batch); ScFormulaOptions aOpt = SC_MOD()->GetFormulaOptions(); aOpt.SetODFRecalcOptions(bHardRecalc ? RECALC_ALWAYS : RECALC_NEVER); diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx index faf655b..8fe2368 100644 --- a/sc/source/ui/unoobj/docuno.cxx +++ b/sc/source/ui/unoobj/docuno.cxx @@ -2351,7 +2351,7 @@ sal_Bool ScModelObj::isOpenCLEnabled() void ScModelObj::enableOpenCL(sal_Bool bEnable) throw (uno::RuntimeException, std::exception) { - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Misc::UseOpenCL::set(bEnable, batch); batch->commit(); @@ -2470,7 +2470,7 @@ namespace { void setOpcodeSubsetTest(bool bFlag) throw (uno::RuntimeException, std::exception) { - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Calc::Formula::Calculation::OpenCLSubsetOnly::set(bFlag, batch); batch->commit(); } @@ -2498,7 +2498,7 @@ sal_Bool ScModelObj::isOpcodeSubsetTested() void ScModelObj::setFormulaCellNumberLimit( sal_Int32 number ) throw (uno::RuntimeException, std::exception) { - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Calc::Formula::Calculation::OpenCLMinimumDataSize::set(number, batch); batch->commit(); } diff --git a/sd/qa/unit/export-tests.cxx b/sd/qa/unit/export-tests.cxx index 19c5ed3..ed02bc9 100644 --- a/sd/qa/unit/export-tests.cxx +++ b/sd/qa/unit/export-tests.cxx @@ -531,7 +531,7 @@ void SdExportTest::testSwappedOutImageExport() }; // Set cache size to a very small value to make sure one of the images is swapped out - boost::shared_ptr< comphelper::ConfigurationChanges > xBatch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > xBatch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), xBatch); xBatch->commit(); @@ -657,7 +657,7 @@ void SdExportTest::testImageWithSpecialID() }; // Trigger swap out mechanism to test swapped state factor too. - boost::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), batch); batch->commit(); diff --git a/sd/source/ui/dlg/PhotoAlbumDialog.cxx b/sd/source/ui/dlg/PhotoAlbumDialog.cxx index 4f3a0a8..e4d5e92 100644 --- a/sd/source/ui/dlg/PhotoAlbumDialog.cxx +++ b/sd/source/ui/dlg/PhotoAlbumDialog.cxx @@ -468,7 +468,7 @@ IMPL_LINK_NOARG(SdPhotoAlbumDialog, FileHdl) sUrl = aDlg.GetDisplayDirectory(); // Write out configuration { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Impress::Pictures::Path::set(sUrl, batch); batch->commit(); diff --git a/sd/source/ui/remotecontrol/Server.cxx b/sd/source/ui/remotecontrol/Server.cxx index d110832..75d5e2e 100644 --- a/sd/source/ui/remotecontrol/Server.cxx +++ b/sd/source/ui/remotecontrol/Server.cxx @@ -288,7 +288,7 @@ bool RemoteServer::connectClient( ::boost::shared_ptr< ClientInfo > pClient, con if ( apClient->mPin.equals( aPin ) ) { // Save in settings first - boost::shared_ptr< ConfigurationChanges > aChanges = ConfigurationChanges::create(); + std::shared_ptr< ConfigurationChanges > aChanges = ConfigurationChanges::create(); Reference< XNameContainer > const xConfig = officecfg::Office::Impress::Misc::AuthorisedRemotes::get( aChanges ); Reference<XSingleServiceFactory> xChildFactory ( @@ -353,7 +353,7 @@ void RemoteServer::deauthoriseClient( ::boost::shared_ptr< ClientInfo > pClient return; } - boost::shared_ptr< ConfigurationChanges > aChanges = ConfigurationChanges::create(); + std::shared_ptr< ConfigurationChanges > aChanges = ConfigurationChanges::create(); Reference< XNameContainer > const xConfig = officecfg::Office::Impress::Misc::AuthorisedRemotes::get( aChanges ); diff --git a/sfx2/source/appl/appbas.cxx b/sfx2/source/appl/appbas.cxx index 18deea8..becd677 100644 --- a/sfx2/source/appl/appbas.cxx +++ b/sfx2/source/appl/appbas.cxx @@ -146,7 +146,7 @@ void SfxApplication::PropExec_Impl( SfxRequest &rReq ) case SID_ATTR_UNDO_COUNT: { SFX_REQUEST_ARG(rReq, pCountItem, SfxUInt16Item, nSID, false); - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Undo::Steps::set( pCountItem->GetValue(), batch); diff --git a/sfx2/source/appl/appcfg.cxx b/sfx2/source/appl/appcfg.cxx index 2a8c7a3..14897f8 100644 --- a/sfx2/source/appl/appcfg.cxx +++ b/sfx2/source/appl/appcfg.cxx @@ -504,7 +504,7 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet ) SvtHelpOptions aHelpOptions; SvtSecurityOptions aSecurityOptions; SvtMiscOptions aMiscOptions; - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); if ( SfxItemState::SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_BUTTON_OUTSTYLE3D), true, &pItem) ) { diff --git a/sfx2/source/dialog/dialoghelper.cxx b/sfx2/source/dialog/dialoghelper.cxx index cbc9579..e7c0af1 100644 --- a/sfx2/source/dialog/dialoghelper.cxx +++ b/sfx2/source/dialog/dialoghelper.cxx @@ -43,7 +43,7 @@ void setPreviewsToSamePlace(vcl::Window *pParent, VclBuilderContainer *pPage) if (aGrids.size() > 1) { - boost::shared_ptr< VclSizeGroup > xGroup(new VclSizeGroup); + std::shared_ptr<VclSizeGroup> xGroup(std::make_shared<VclSizeGroup>()); for (std::vector<vcl::Window*>::iterator aI = aGrids.begin(); aI != aGrids.end(); ++aI) { vcl::Window *pWindow = *aI; diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx index c361aa2..094bc96 100644 --- a/sfx2/source/doc/templatedlg.cxx +++ b/sfx2/source/doc/templatedlg.cxx @@ -611,9 +611,9 @@ IMPL_LINK(SfxTemplateManagerDlg, RepositoryMenuSelectHdl, Menu*, pMenu) if (dlg.Execute()) { - boost::shared_ptr<Place> pPlace = dlg.GetPlace(); + std::shared_ptr<Place> xPlace = dlg.GetPlace(); - if (insertRepository(pPlace->GetName(),pPlace->GetUrl())) + if (insertRepository(xPlace->GetName(), xPlace->GetUrl())) { // update repository list menu. createRepositoryMenu(); @@ -621,7 +621,7 @@ IMPL_LINK(SfxTemplateManagerDlg, RepositoryMenuSelectHdl, Menu*, pMenu) else { OUString aMsg(SfxResId(STR_MSG_ERROR_REPOSITORY_NAME).toString()); - aMsg = aMsg.replaceFirst("$1",pPlace->GetName()); + aMsg = aMsg.replaceFirst("$1", xPlace->GetName()); MessageDialog(this, aMsg).Execute(); } } @@ -1659,7 +1659,7 @@ void SfxTemplateManagerDlg::syncRepositories() const if (!mbIsSynced) { uno::Reference < uno::XComponentContext > pContext(comphelper::getProcessComponentContext()); - boost::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create(pContext)); + std::shared_ptr<comphelper::ConfigurationChanges> batch(comphelper::ConfigurationChanges::create(pContext)); size_t nSize = maRepositories.size(); uno::Sequence<OUString> aUrls(nSize); diff --git a/sfx2/source/view/viewimp.hxx b/sfx2/source/view/viewimp.hxx index c07fbc6..5d1e848 100644 --- a/sfx2/source/view/viewimp.hxx +++ b/sfx2/source/view/viewimp.hxx @@ -58,10 +58,10 @@ struct SfxViewShell_Impl bool m_bGotFrameOwnership; sal_uInt16 m_nFamily; ::rtl::Reference<SfxBaseController> m_pController; - ::std::unique_ptr< ::svt::AcceleratorExecute > m_pAccExec; + std::unique_ptr< ::svt::AcceleratorExecute > m_xAccExec; com::sun::star::uno::Sequence < com::sun::star::beans::PropertyValue > aPrintOpts; ::rtl::Reference< SfxClipboardChangeListener > xClipboardListener; - ::boost::shared_ptr< vcl::PrinterController > m_pPrinterController; + std::shared_ptr< vcl::PrinterController > m_xPrinterController; mutable SfxInPlaceClientList* mpIPClientList; diff --git a/sfx2/source/view/viewprn.cxx b/sfx2/source/view/viewprn.cxx index 4130262..0ed526d 100644 --- a/sfx2/source/view/viewprn.cxx +++ b/sfx2/source/view/viewprn.cxx @@ -74,7 +74,7 @@ class SfxPrinterController : public vcl::PrinterController, public SfxListener const Any& getSelectionObject() const; public: - SfxPrinterController( const boost::shared_ptr<Printer>& i_rPrinter, + SfxPrinterController( const std::shared_ptr<Printer>& i_rPrinter, const Any& i_rComplete, const Any& i_rSelection, const Any& i_rViewProp, @@ -94,7 +94,7 @@ public: virtual void jobFinished( com::sun::star::view::PrintableState ) SAL_OVERRIDE; }; -SfxPrinterController::SfxPrinterController( const boost::shared_ptr<Printer>& i_rPrinter, +SfxPrinterController::SfxPrinterController( const std::shared_ptr<Printer>& i_rPrinter, const Any& i_rComplete, const Any& i_rSelection, const Any& i_rViewProp, @@ -204,10 +204,10 @@ const Any& SfxPrinterController::getSelectionObject() const Sequence< beans::PropertyValue > SfxPrinterController::getMergedOptions() const { - boost::shared_ptr<Printer> pPrinter( getPrinter() ); - if( pPrinter.get() != mpLastPrinter ) + std::shared_ptr<Printer> xPrinter(getPrinter()); + if (xPrinter.get() != mpLastPrinter) { - mpLastPrinter = pPrinter.get(); + mpLastPrinter = xPrinter.get(); VCLXDevice* pXDevice = new VCLXDevice(); pXDevice->SetOutputDevice( mpLastPrinter ); mxDevice = Reference< awt::XDevice >( pXDevice ); @@ -224,8 +224,8 @@ Sequence< beans::PropertyValue > SfxPrinterController::getMergedOptions() const int SfxPrinterController::getPageCount() const { int nPages = 0; - boost::shared_ptr<Printer> pPrinter( getPrinter() ); - if( mxRenderable.is() && pPrinter ) + std::shared_ptr<Printer> xPrinter(getPrinter()); + if (mxRenderable.is() && xPrinter) { Sequence< beans::PropertyValue > aJobOptions( getMergedOptions() ); try @@ -244,10 +244,10 @@ int SfxPrinterController::getPageCount() const Sequence< beans::PropertyValue > SfxPrinterController::getPageParameters( int i_nPage ) const { - boost::shared_ptr<Printer> pPrinter( getPrinter() ); + std::shared_ptr<Printer> xPrinter(getPrinter()); Sequence< beans::PropertyValue > aResult; - if( mxRenderable.is() && pPrinter ) + if (mxRenderable.is() && xPrinter) { Sequence< beans::PropertyValue > aJobOptions( getMergedOptions() ); try @@ -269,8 +269,8 @@ Sequence< beans::PropertyValue > SfxPrinterController::getPageParameters( int i_ void SfxPrinterController::printPage( int i_nPage ) const { - boost::shared_ptr<Printer> pPrinter( getPrinter() ); - if( mxRenderable.is() && pPrinter ) + std::shared_ptr<Printer> xPrinter(getPrinter()); + if (mxRenderable.is() && xPrinter) { Sequence< beans::PropertyValue > aJobOptions( getMergedOptions() ); try @@ -396,7 +396,7 @@ void SfxPrinterController::jobFinished( com::sun::star::view::PrintableState nSt if ( mpViewShell ) { - mpViewShell->pImp->m_pPrinterController.reset(); + mpViewShell->pImp->m_xPrinterController.reset(); } } } @@ -580,7 +580,7 @@ void SfxViewShell::ExecPrint( const uno::Sequence < beans::PropertyValue >& rPro aSelection <<= GetObjectShell()->GetModel(); Any aComplete( makeAny( GetObjectShell()->GetModel() ) ); Any aViewProp( makeAny( xController ) ); - boost::shared_ptr<Printer> aPrt; + std::shared_ptr<Printer> aPrt; const beans::PropertyValue* pVal = rProps.getConstArray(); for( sal_Int32 i = 0; i < rProps.getLength(); i++ ) @@ -594,7 +594,7 @@ void SfxViewShell::ExecPrint( const uno::Sequence < beans::PropertyValue >& rPro } } - boost::shared_ptr<vcl::PrinterController> pController( new SfxPrinterController( + std::shared_ptr<vcl::PrinterController> xNewController(std::make_shared<SfxPrinterController>( aPrt, aComplete, aSelection, @@ -604,23 +604,23 @@ void SfxViewShell::ExecPrint( const uno::Sequence < beans::PropertyValue >& rPro bIsDirect, this, rProps - ) ); - pImp->m_pPrinterController = pController; + )); + pImp->m_xPrinterController = xNewController; SfxObjectShell *pObjShell = GetObjectShell(); - pController->setValue( OUString( "JobName" ), + xNewController->setValue( OUString( "JobName" ), makeAny( OUString( pObjShell->GetTitle(0) ) ) ); // FIXME: job setup SfxPrinter* pDocPrt = GetPrinter(false); JobSetup aJobSetup = pDocPrt ? pDocPrt->GetJobSetup() : GetJobSetup(); - Printer::PrintJob( pController, aJobSetup ); + Printer::PrintJob( xNewController, aJobSetup ); } Printer* SfxViewShell::GetActivePrinter() const { - return (pImp->m_pPrinterController) - ? pImp->m_pPrinterController->getPrinter().get() : 0; + return (pImp->m_xPrinterController) + ? pImp->m_xPrinterController->getPrinter().get() : 0; } void SfxViewShell::ExecPrint_Impl( SfxRequest &rReq ) diff --git a/sfx2/source/view/viewsh.cxx b/sfx2/source/view/viewsh.cxx index 8d1fe44..c16d285 100644 --- a/sfx2/source/view/viewsh.cxx +++ b/sfx2/source/view/viewsh.cxx @@ -1640,23 +1640,19 @@ void SfxViewShell::Notify( SfxBroadcaster& rBC, } } - - bool SfxViewShell::ExecKey_Impl(const KeyEvent& aKey) { - if (!pImp->m_pAccExec.get()) + if (!pImp->m_xAccExec.get()) { - pImp->m_pAccExec.reset( + pImp->m_xAccExec.reset( ::svt::AcceleratorExecute::createAcceleratorHelper() ); - pImp->m_pAccExec->init(::comphelper::getProcessComponentContext(), + pImp->m_xAccExec->init(::comphelper::getProcessComponentContext(), pFrame->GetFrame().GetFrameInterface()); } - return pImp->m_pAccExec->execute(aKey.GetKeyCode()); + return pImp->m_xAccExec->execute(aKey.GetKeyCode()); } - - bool SfxViewShell::KeyInput( const KeyEvent &rKeyEvent ) /* [Description] diff --git a/svl/source/config/asiancfg.cxx b/svl/source/config/asiancfg.cxx index f06c909..c67f86d 100644 --- a/svl/source/config/asiancfg.cxx +++ b/svl/source/config/asiancfg.cxx @@ -63,7 +63,7 @@ struct SvxAsianConfig::Impl: private boost::noncopyable { css::uno::Reference< css::uno::XComponentContext > context; - boost::shared_ptr< comphelper::ConfigurationChanges > batch; + std::shared_ptr< comphelper::ConfigurationChanges > batch; }; SvxAsianConfig::SvxAsianConfig(): impl_(new Impl) {} diff --git a/svtools/qa/unit/GraphicObjectTest.cxx b/svtools/qa/unit/GraphicObjectTest.cxx index 3c4645b..e2ef583 100644 --- a/svtools/qa/unit/GraphicObjectTest.cxx +++ b/svtools/qa/unit/GraphicObjectTest.cxx @@ -146,7 +146,7 @@ void GraphicObjectTest::testSizeBasedAutoSwap() { // Set cache size to a very small value to check what happens { - boost::shared_ptr< comphelper::ConfigurationChanges > aBatch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > aBatch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), aBatch); aBatch->commit(); } diff --git a/svtools/source/dialogs/PlaceEditDialog.cxx b/svtools/source/dialogs/PlaceEditDialog.cxx index e63ce87..f6a76fa 100644 --- a/svtools/source/dialogs/PlaceEditDialog.cxx +++ b/svtools/source/dialogs/PlaceEditDialog.cxx @@ -14,11 +14,9 @@ #include <svtools/svtresid.hxx> #include <vcl/msgbox.hxx> -using namespace boost; - -PlaceEditDialog::PlaceEditDialog( vcl::Window* pParent ) : - ModalDialog( pParent, "PlaceEditDialog", "svt/ui/placeedit.ui" ), - m_pCurrentDetails( ) +PlaceEditDialog::PlaceEditDialog(vcl::Window* pParent) + : ModalDialog(pParent, "PlaceEditDialog", "svt/ui/placeedit.ui") + , m_xCurrentDetails() { get( m_pEDServerName, "name" ); get( m_pLBServerType, "type" ); @@ -42,9 +40,9 @@ PlaceEditDialog::PlaceEditDialog( vcl::Window* pParent ) : InitDetails( ); } -PlaceEditDialog::PlaceEditDialog( vcl::Window* pParent, const boost::shared_ptr<Place>& pPlace ) : - ModalDialog( pParent, "PlaceEditDialog", "svt/ui/placeedit.ui" ), - m_pCurrentDetails( ) +PlaceEditDialog::PlaceEditDialog(vcl::Window* pParent, const std::shared_ptr<Place>& rPlace) + : ModalDialog(pParent, "PlaceEditDialog", "svt/ui/placeedit.ui") + , m_xCurrentDetails( ) { get( m_pEDServerName, "name" ); get( m_pLBServerType, "type" ); @@ -61,13 +59,13 @@ PlaceEditDialog::PlaceEditDialog( vcl::Window* pParent, const boost::shared_ptr< InitDetails( ); - m_pEDServerName->SetText( pPlace->GetName() ); + m_pEDServerName->SetText(rPlace->GetName()); // Fill the boxes with the URL parts bool bSuccess = false; - for ( size_t i = 0 ; i < m_aDetailsContainers.size( ) && !bSuccess; ++i ) + for (size_t i = 0 ; i < m_aDetailsContainers.size( ) && !bSuccess; ++i) { - INetURLObject& rUrl = pPlace->GetUrlObject( ); + INetURLObject& rUrl = rPlace->GetUrlObject(); bSuccess = m_aDetailsContainers[i]->setUrl( rUrl ); if ( bSuccess ) { @@ -88,9 +86,9 @@ PlaceEditDialog::~PlaceEditDialog() OUString PlaceEditDialog::GetServerUrl() { OUString sUrl; - if ( m_pCurrentDetails.get( ) ) + if (m_xCurrentDetails.get()) { - INetURLObject aUrl = m_pCurrentDetails->getUrl(); + INetURLObject aUrl = m_xCurrentDetails->getUrl(); OUString sUsername = OUString( m_pEDUsername->GetText( ) ).trim( ); if ( !sUsername.isEmpty( ) ) aUrl.SetUser( sUsername ); @@ -101,36 +99,35 @@ OUString PlaceEditDialog::GetServerUrl() return sUrl; } -boost::shared_ptr<Place> PlaceEditDialog::GetPlace() +std::shared_ptr<Place> PlaceEditDialog::GetPlace() { - boost::shared_ptr<Place> newPlace( new Place( m_pEDServerName->GetText(), GetServerUrl(), true ) ); - return newPlace; + return std::make_shared<Place>(m_pEDServerName->GetText(), GetServerUrl(), true); } void PlaceEditDialog::InitDetails( ) { // Create WebDAV / FTP / SSH details control - shared_ptr< DetailsContainer > pDavDetails( new DavDetailsContainer( this ) ); - pDavDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); - m_aDetailsContainers.push_back( pDavDetails ); + std::shared_ptr<DetailsContainer> xDavDetails(std::make_shared<DavDetailsContainer>(this)); + xDavDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); + m_aDetailsContainers.push_back(xDavDetails); - shared_ptr< DetailsContainer > pFtpDetails( new HostDetailsContainer( this, 21, "ftp" ) ); - pFtpDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); - m_aDetailsContainers.push_back( pFtpDetails ); + std::shared_ptr<DetailsContainer> xFtpDetails(std::make_shared<HostDetailsContainer>(this, 21, "ftp")); + xFtpDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); + m_aDetailsContainers.push_back(xFtpDetails); - shared_ptr< DetailsContainer > pSshDetails( new HostDetailsContainer( this, 22, "ssh" ) ); - pSshDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); - m_aDetailsContainers.push_back( pSshDetails ); + std::shared_ptr<DetailsContainer> xSshDetails(std::make_shared<HostDetailsContainer>(this, 22, "ssh")); + xSshDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); + m_aDetailsContainers.push_back(xSshDetails); // Create Windows Share control - shared_ptr< DetailsContainer > pSmbDetails( new SmbDetailsContainer( this ) ); - pSmbDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); - m_aDetailsContainers.push_back( pSmbDetails ); + std::shared_ptr<DetailsContainer> xSmbDetails(std::make_shared<SmbDetailsContainer>(this)); + xSmbDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); + m_aDetailsContainers.push_back(xSmbDetails); // Create CMIS control - shared_ptr< DetailsContainer > pCmisDetails( new CmisDetailsContainer( this ) ); - pCmisDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); - m_aDetailsContainers.push_back( pCmisDetails ); + std::shared_ptr<DetailsContainer> xCmisDetails(std::make_shared<CmisDetailsContainer>(this)); + xCmisDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); + m_aDetailsContainers.push_back(xCmisDetails); // Set default to first value m_pLBServerType->SelectEntryPos( 0 ); @@ -160,7 +157,7 @@ IMPL_LINK ( PlaceEditDialog, EditHdl, void *, EMPTYARG ) IMPL_LINK ( PlaceEditDialog, EditUsernameHdl, void *, EMPTYARG ) { - for ( std::vector< boost::shared_ptr< DetailsContainer > >::iterator it = m_aDetailsContainers.begin( ); + for ( std::vector< std::shared_ptr< DetailsContainer > >::iterator it = m_aDetailsContainers.begin( ); it != m_aDetailsContainers.end( ); ++it ) { ( *it )->setUsername( OUString( m_pEDUsername->GetText() ) ); @@ -170,13 +167,13 @@ IMPL_LINK ( PlaceEditDialog, EditUsernameHdl, void *, EMPTYARG ) IMPL_LINK( PlaceEditDialog, SelectTypeHdl, void*, EMPTYARG ) { - if ( m_pCurrentDetails.get( ) ) - m_pCurrentDetails->show( false ); + if (m_xCurrentDetails.get()) + m_xCurrentDetails->show(false); sal_uInt16 nPos = m_pLBServerType->GetSelectEntryPos( ); - m_pCurrentDetails = m_aDetailsContainers[nPos]; + m_xCurrentDetails = m_aDetailsContainers[nPos]; - m_pCurrentDetails->show( true ); + m_xCurrentDetails->show(true); SetSizePixel(GetOptimalSize()); return 0; diff --git a/sw/qa/extras/globalfilter/globalfilter.cxx b/sw/qa/extras/globalfilter/globalfilter.cxx index a88292a..ae87472 100644 --- a/sw/qa/extras/globalfilter/globalfilter.cxx +++ b/sw/qa/extras/globalfilter/globalfilter.cxx @@ -51,7 +51,7 @@ void Test::testSwappedOutImageExport() // Check whether the export code swaps in the image which was swapped out before by auto mechanism // Set cache size to a very small value to make sure one of the images is swapped out - boost::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), batch); batch->commit(); @@ -195,7 +195,7 @@ void Test::testImageWithSpecialID() }; // Trigger swap out mechanism to test swapped state factor too. - boost::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), batch); batch->commit(); @@ -276,7 +276,7 @@ void Test::testGraphicShape() }; // Trigger swap out mechanism to test swapped state factor too. - boost::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); + std::shared_ptr< comphelper::ConfigurationChanges > batch(comphelper::ConfigurationChanges::create()); officecfg::Office::Common::Cache::GraphicManager::TotalCacheSize::set(sal_Int32(1), batch); batch->commit(); diff --git a/sw/source/ui/config/optload.cxx b/sw/source/ui/config/optload.cxx index e7dd53b..b665e82 100644 --- a/sw/source/ui/config/optload.cxx +++ b/sw/source/ui/config/optload.cxx @@ -201,7 +201,7 @@ bool SwLoadOptPage::FillItemSet( SfxItemSet* rSet ) if( m_pWordCountED->IsValueChangedFromSaved() ) { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Writer::WordCount::AdditionalSeparators::set(m_pWordCountED->GetText(), batch); batch->commit(); @@ -210,7 +210,7 @@ bool SwLoadOptPage::FillItemSet( SfxItemSet* rSet ) if (m_pShowStandardizedPageCount->GetState() != m_pShowStandardizedPageCount->GetSavedValue()) { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Writer::WordCount::ShowStandardizedPageCount::set( m_pShowStandardizedPageCount->IsChecked(), @@ -221,7 +221,7 @@ bool SwLoadOptPage::FillItemSet( SfxItemSet* rSet ) if (m_pStandardizedPageSizeNF->GetText() != m_pStandardizedPageSizeNF->GetSavedValue()) { - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Writer::WordCount::StandardizedPageSize::set( m_pStandardizedPageSizeNF->GetValue(), diff --git a/toolkit/source/awt/vclxprinter.cxx b/toolkit/source/awt/vclxprinter.cxx index 15adc11..c80caae 100644 --- a/toolkit/source/awt/vclxprinter.cxx +++ b/toolkit/source/awt/vclxprinter.cxx @@ -70,7 +70,7 @@ IMPLEMENT_FORWARD_XTYPEPROVIDER2( VCLXPrinterPropertySet, VCLXPrinterPropertySet VCLXPrinterPropertySet::VCLXPrinterPropertySet( const OUString& rPrinterName ) : OPropertySetHelper( BrdcstHelper ) - , mpPrinter( new Printer( rPrinterName ) ) + , mxPrinter(std::make_shared<Printer>(rPrinterName)) { SolarMutexGuard aSolarGuard; @@ -81,7 +81,7 @@ VCLXPrinterPropertySet::VCLXPrinterPropertySet( const OUString& rPrinterName ) VCLXPrinterPropertySet::~VCLXPrinterPropertySet() { SolarMutexGuard aSolarGuard; - mpPrinter.reset(); + mxPrinter.reset(); } ::com::sun::star::uno::Reference< ::com::sun::star::awt::XDevice > VCLXPrinterPropertySet::GetDevice() @@ -280,10 +280,10 @@ sal_Bool VCLXPrinter::start( const OUString& /*rJobName*/, sal_Int16 /*nCopies*/ ::osl::MutexGuard aGuard( Mutex ); bool bDone = true; - if ( mpPrinter.get() ) + if (mxPrinter.get()) { - maInitJobSetup = mpPrinter->GetJobSetup(); - mpListener.reset( new vcl::OldStylePrintAdaptor( mpPrinter ) ); + maInitJobSetup = mxPrinter->GetJobSetup(); + mxListener.reset(new vcl::OldStylePrintAdaptor(mxPrinter)); } return bDone; @@ -293,10 +293,10 @@ void VCLXPrinter::end( ) throw(::com::sun::star::awt::PrinterException, ::com:: { ::osl::MutexGuard aGuard( Mutex ); - if ( mpListener.get() ) + if (mxListener.get()) { - Printer::PrintJob( mpListener, maInitJobSetup ); - mpListener.reset(); + Printer::PrintJob(mxListener, maInitJobSetup); + mxListener.reset(); } } @@ -304,16 +304,16 @@ void VCLXPrinter::terminate( ) throw(::com::sun::star::uno::RuntimeException, s { ::osl::MutexGuard aGuard( Mutex ); - mpListener.reset(); + mxListener.reset(); } ::com::sun::star::uno::Reference< ::com::sun::star::awt::XDevice > VCLXPrinter::startPage( ) throw(::com::sun::star::awt::PrinterException, ::com::sun::star::uno::RuntimeException, std::exception) { ::osl::MutexGuard aGuard( Mutex ); - if ( mpListener.get() ) + if (mxListener.get()) { - mpListener->StartPage(); + mxListener->StartPage(); } return GetDevice(); } @@ -322,9 +322,9 @@ void VCLXPrinter::endPage( ) throw(::com::sun::star::awt::PrinterException, ::c { ::osl::MutexGuard aGuard( Mutex ); - if ( mpListener.get() ) + if (mxListener.get()) { - mpListener->EndPage(); + mxListener->EndPage(); } } diff --git a/unotools/source/config/saveopt.cxx b/unotools/source/config/saveopt.cxx index fa7e065..9031dee 100644 --- a/unotools/source/config/saveopt.cxx +++ b/unotools/source/config/saveopt.cxx @@ -736,7 +736,7 @@ void SvtSaveOptions_Impl::Commit() aValues.realloc(nRealCount); PutProperties( aNames, aValues ); - boost::shared_ptr< comphelper::ConfigurationChanges > batch( + std::shared_ptr< comphelper::ConfigurationChanges > batch( comphelper::ConfigurationChanges::create()); officecfg::Office::Recovery::AutoSave::TimeIntervall::set(nAutoSaveTime, batch); officecfg::Office::Recovery::AutoSave::Enabled::set(bAutoSave, batch); diff --git a/vcl/generic/glyphs/gcach_ftyp.cxx b/vcl/generic/glyphs/gcach_ftyp.cxx index 635abb3..16f123f 100644 --- a/vcl/generic/glyphs/gcach_ftyp.cxx +++ b/vcl/generic/glyphs/gcach_ftyp.cxx @@ -93,7 +93,7 @@ static FT_Library aLibFT = 0; // enable linking with old FT versions static int nFTVERSION = 0; -typedef std::unordered_map<const char*, boost::shared_ptr<FtFontFile>, rtl::CStringHash, rtl::CStringEqual> FontFileList; +typedef std::unordered_map<const char*, std::shared_ptr<FtFontFile>, rtl::CStringHash, rtl::CStringEqual> FontFileList; namespace { struct vclFontFileList : public rtl::Static< FontFileList, vclFontFileList > {}; } @@ -558,14 +558,14 @@ ServerFont::ServerFont( const FontSelectPattern& rFSD, FtFontInfo* pFI ) mnLoadFlags |= FT_LOAD_NO_BITMAP; } -void ServerFont::SetFontOptions( boost::shared_ptr<ImplFontOptions> pFontOptions) +void ServerFont::SetFontOptions(std::shared_ptr<ImplFontOptions> xFontOptions) { - mpFontOptions = pFontOptions; + mxFontOptions = xFontOptions; - if (!mpFontOptions) + if (!mxFontOptions) return; - FontAutoHint eHint = mpFontOptions->GetUseAutoHint(); + FontAutoHint eHint = mxFontOptions->GetUseAutoHint(); if( eHint == AUTOHINT_DONTKNOW ) eHint = mbUseGamma ? AUTOHINT_TRUE : AUTOHINT_FALSE; @@ -576,11 +576,11 @@ void ServerFont::SetFontOptions( boost::shared_ptr<ImplFontOptions> pFontOptions mnLoadFlags |= FT_LOAD_NO_HINTING; mnLoadFlags |= FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH; //#88334# - if( mpFontOptions->DontUseAntiAlias() ) + if (mxFontOptions->DontUseAntiAlias()) mnPrioAntiAlias = 0; - if( mpFontOptions->DontUseEmbeddedBitmaps() ) + if (mxFontOptions->DontUseEmbeddedBitmaps()) mnPrioEmbedded = 0; - if( mpFontOptions->DontUseHinting() ) + if (mxFontOptions->DontUseHinting()) mnPrioAutoHint = 0; if( mnPrioAutoHint <= 0 ) @@ -590,7 +590,7 @@ void ServerFont::SetFontOptions( boost::shared_ptr<ImplFontOptions> pFontOptions if( !(mnLoadFlags & FT_LOAD_NO_HINTING) ) { mnLoadFlags |= FT_LOAD_TARGET_NORMAL; - switch( mpFontOptions->GetHintStyle() ) + switch (mxFontOptions->GetHintStyle()) { case HINT_NONE: mnLoadFlags |= FT_LOAD_NO_HINTING; @@ -611,9 +611,9 @@ void ServerFont::SetFontOptions( boost::shared_ptr<ImplFontOptions> pFontOptions mnLoadFlags |= FT_LOAD_NO_BITMAP; } -boost::shared_ptr<ImplFontOptions> ServerFont::GetFontOptions() const +std::shared_ptr<ImplFontOptions> ServerFont::GetFontOptions() const { - return mpFontOptions; + return mxFontOptions; } const OString& ServerFont::GetFontFileName() const diff --git a/vcl/generic/print/genprnpsp.cxx b/vcl/generic/print/genprnpsp.cxx index 02d2ab9..02de546 100644 --- a/vcl/generic/print/genprnpsp.cxx +++ b/vcl/generic/print/genprnpsp.cxx @@ -1070,14 +1070,14 @@ bool PspSalPrinter::StartJob( const OUString* i_pFileName, const OUString& i_rJo boost::shared_ptr<vcl::PDFWriter> pWriter; std::vector< PDFPrintFile > aPDFFiles; - boost::shared_ptr<Printer> pPrinter( i_rController.getPrinter() ); + std::shared_ptr<Printer> xPrinter(i_rController.getPrinter()); int nAllPages = i_rController.getFilteredPageCount(); i_rController.createProgressDialog(); bool bAborted = false; PDFNewJobParameters aLastParm; - aContext.DPIx = pPrinter->GetDPIX(); - aContext.DPIy = pPrinter->GetDPIY(); + aContext.DPIx = xPrinter->GetDPIX(); + aContext.DPIy = xPrinter->GetDPIY(); for( int nPage = 0; nPage < nAllPages && ! bAborted; nPage++ ) { if( nPage == nAllPages-1 ) @@ -1098,9 +1098,9 @@ bool PspSalPrinter::StartJob( const OUString* i_pFileName, const OUString& i_rJo } else { - pPrinter->SetMapMode( MapMode( MAP_100TH_MM ) ); - pPrinter->SetPaperSizeUser( aPageSize.aSize, true ); - PDFNewJobParameters aNewParm( pPrinter->GetPaperSize(), pPrinter->GetPaperBin() ); + xPrinter->SetMapMode( MapMode( MAP_100TH_MM ) ); + xPrinter->SetPaperSizeUser( aPageSize.aSize, true ); + PDFNewJobParameters aNewParm(xPrinter->GetPaperSize(), xPrinter->GetPaperBin()); // create PDF writer on demand // either on first page @@ -1162,7 +1162,7 @@ bool PspSalPrinter::StartJob( const OUString* i_pFileName, const OUString& i_rJo { if( bCollate ) { - if( aPDFFiles.size() == 1 && pPrinter->HasSupport( SUPPORT_COLLATECOPY ) ) + if (aPDFFiles.size() == 1 && xPrinter->HasSupport(SUPPORT_COLLATECOPY)) { m_aJobData.setCollate( true ); m_aJobData.m_nCopies = nCopies; @@ -1219,7 +1219,7 @@ bool PspSalPrinter::StartJob( const OUString* i_pFileName, const OUString& i_rJo m_aJobData.setPaperBin( aPDFFiles[i].maParameters.mnPaperBin ); // spool current file - FILE* fp = PrinterInfoManager::get().startSpool( pPrinter->GetName(), i_rController.isDirectPrint() ); + FILE* fp = PrinterInfoManager::get().startSpool(xPrinter->GetName(), i_rController.isDirectPrint()); if( fp ) { sal_uInt64 nBytesRead = 0; @@ -1242,7 +1242,7 @@ bool PspSalPrinter::StartJob( const OUString* i_pFileName, const OUString& i_rJo aBuf.append( sal_Int32( i + nCurJob * aPDFFiles.size() ) ); } bSuccess &= - PrinterInfoManager::get().endSpool( pPrinter->GetName(), aBuf.makeStringAndClear(), fp, m_aJobData, bFirstJob, sFaxNumber ); + PrinterInfoManager::get().endSpool(xPrinter->GetName(), aBuf.makeStringAndClear(), fp, m_aJobData, bFirstJob, sFaxNumber); bFirstJob = false; } } diff --git a/vcl/inc/generic/glyphcache.hxx b/vcl/inc/generic/glyphcache.hxx index b5e8d75..382e70c 100644 --- a/vcl/inc/generic/glyphcache.hxx +++ b/vcl/inc/generic/glyphcache.hxx @@ -26,8 +26,6 @@ #include FT_FREETYPE_H #include FT_GLYPH_H -#include <boost/shared_ptr.hpp> - #include <basebmp/bitmapdevice.hxx> #include <com/sun/star/i18n/XBreakIterator.hpp> #include <tools/gen.hxx> @@ -176,8 +174,8 @@ public: bool TestFont() const { return mbFaceOk;} FT_Face GetFtFace() const; int GetLoadFlags() const { return (mnLoadFlags & ~FT_LOAD_IGNORE_TRANSFORM); } - void SetFontOptions( boost::shared_ptr<ImplFontOptions> ); - boost::shared_ptr<ImplFontOptions> GetFontOptions() const; + void SetFontOptions(std::shared_ptr<ImplFontOptions>); + std::shared_ptr<ImplFontOptions> GetFontOptions() const; bool NeedsArtificialBold() const { return mbArtBold; } bool NeedsArtificialItalic() const { return mbArtItalic; } @@ -255,7 +253,7 @@ private: FT_FaceRec_* maFaceFT; FT_SizeRec_* maSizeFT; - boost::shared_ptr<ImplFontOptions> mpFontOptions; + std::shared_ptr<ImplFontOptions> mxFontOptions; bool mbFaceOk; bool mbArtItalic; @@ -280,7 +278,7 @@ public: private: ServerFont* mpServerFont; - boost::shared_ptr<ImplFontOptions> mpFontOptions; + std::shared_ptr<ImplFontOptions> mxFontOptions; bool mbGotFontOptions; }; diff --git a/vcl/inc/impimagetree.hxx b/vcl/inc/impimagetree.hxx index 0fbb276..4a5e3a6 100644 --- a/vcl/inc/impimagetree.hxx +++ b/vcl/inc/impimagetree.hxx @@ -22,10 +22,10 @@ #include "sal/config.h" +#include <memory> #include <unordered_map> #include <vector> -#include "boost/noncopyable.hpp" #include "com/sun/star/uno/Reference.hxx" #include "rtl/ustring.hxx" #include "salhelper/singletonref.hxx" @@ -95,7 +95,7 @@ private: void loadImageLinks(); - void parseLinkFile(boost::shared_ptr< SvStream > stream); + void parseLinkFile(std::shared_ptr<SvStream> stream); /// Return name of a real .png according to links.txt. OUString const & getRealImageName(OUString const & name); diff --git a/vcl/inc/pch/precompiled_vcl.hxx b/vcl/inc/pch/precompiled_vcl.hxx index 715615e..56db30f 100644 --- a/vcl/inc/pch/precompiled_vcl.hxx +++ b/vcl/inc/pch/precompiled_vcl.hxx @@ -137,7 +137,6 @@ #include <basegfx/vector/b2isize.hxx> #include <boost/bind.hpp> #include <boost/functional/hash.hpp> -#include <boost/make_shared.hpp> #include <boost/mem_fn.hpp> #include <boost/optional.hpp> #include <boost/ptr_container/ptr_vector.hpp> diff --git a/vcl/inc/printdlg.hxx b/vcl/inc/printdlg.hxx index 49c97e3..ab6adbb 100644 --- a/vcl/inc/printdlg.hxx +++ b/vcl/inc/printdlg.hxx @@ -36,7 +36,7 @@ #include "vcl/tabpage.hxx" #include "vcl/virdev.hxx" -#include <boost/shared_ptr.hpp> +#include <memory> #include <map> namespace vcl @@ -186,7 +186,7 @@ namespace vcl VclBuilder* mpCustomOptionsUIBuilder; - boost::shared_ptr< PrinterController > maPController; + std::shared_ptr<PrinterController> maPController; TabControl* mpTabCtrl; NUpTabPage maNUpPage; JobTabPage maJobPage; @@ -258,7 +258,7 @@ namespace vcl DECL_LINK( UIOption_ModifyHdl, Edit* ); public: - PrintDialog( vcl::Window*, const boost::shared_ptr< PrinterController >& ); + PrintDialog( vcl::Window*, const std::shared_ptr< PrinterController >& ); virtual ~PrintDialog(); bool isPrintToFile(); diff --git a/vcl/inc/window.h b/vcl/inc/window.h index 6e6129b..e14c1c5 100644 --- a/vcl/inc/window.h +++ b/vcl/inc/window.h @@ -258,8 +258,8 @@ public: InputContext maInputContext; ::com::sun::star::uno::Reference< ::com::sun::star::awt::XWindowPeer > mxWindowPeer; ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > mxAccessible; - ::boost::shared_ptr< VclSizeGroup > m_xSizeGroup; - ::std::vector< FixedText* > m_aMnemonicLabels; + std::shared_ptr<VclSizeGroup> m_xSizeGroup; + std::vector<FixedText*> m_aMnemonicLabels; ImplAccessibleInfos* mpAccessibleInfos; VCLXWindow* mpVCLXWindow; vcl::Region maWinRegion; //< region to 'shape' the VCL window (frame coordinates) diff --git a/vcl/source/app/IconThemeScanner.cxx b/vcl/source/app/IconThemeScanner.cxx index 8cb58fe..45346cb 100644 --- a/vcl/source/app/IconThemeScanner.cxx +++ b/vcl/source/app/IconThemeScanner.cxx @@ -154,10 +154,10 @@ IconThemeScanner::IconThemeIsInstalled(const OUString& themeId) const return IconThemeInfo::IconThemeIsInVector(mFoundIconThemes, themeId); } -/*static*/ boost::shared_ptr<IconThemeScanner> +/*static*/ std::shared_ptr<IconThemeScanner> IconThemeScanner::Create(const OUString &path) { - boost::shared_ptr<IconThemeScanner> retval(new IconThemeScanner); + std::shared_ptr<IconThemeScanner> retval(new IconThemeScanner); retval->ScanDirectoryForIconThemes(path); return retval; } diff --git a/vcl/source/app/settings.cxx b/vcl/source/app/settings.cxx index 57377ff..bc6f1319 100644 --- a/vcl/source/app/settings.cxx +++ b/vcl/source/app/settings.cxx @@ -55,8 +55,6 @@ using namespace ::com::sun::star; #include "svdata.hxx" #include "impimagetree.hxx" -#include <boost/make_shared.hpp> - struct ImplMouseData { ImplMouseData(); @@ -174,9 +172,9 @@ struct ImplStyleData bool mnUseFlatBorders; bool mbPreferredUseImagesInMenus; long mnMinThumbSize; - boost::shared_ptr<vcl::IconThemeScanner> + std::shared_ptr<vcl::IconThemeScanner> mIconThemeScanner; - boost::shared_ptr<vcl::IconThemeSelector> + std::shared_ptr<vcl::IconThemeSelector> mIconThemeSelector; rtl::OUString mIconTheme; @@ -294,179 +292,179 @@ void MouseSettings::SetOptions(sal_uLong nOptions) { CopyData(); - mpData->mnOptions = nOptions; + mxData->mnOptions = nOptions; } sal_uLong MouseSettings::GetOptions() const { - return mpData->mnOptions; + return mxData->mnOptions; } void MouseSettings::SetDoubleClickTime( sal_uLong nDoubleClkTime ) { CopyData(); - mpData->mnDoubleClkTime = nDoubleClkTime; + mxData->mnDoubleClkTime = nDoubleClkTime; } sal_uLong MouseSettings::GetDoubleClickTime() const { - return mpData->mnDoubleClkTime; + return mxData->mnDoubleClkTime; } void MouseSettings::SetDoubleClickWidth( long nDoubleClkWidth ) { CopyData(); - mpData->mnDoubleClkWidth = nDoubleClkWidth; + mxData->mnDoubleClkWidth = nDoubleClkWidth; } long MouseSettings::GetDoubleClickWidth() const { - return mpData->mnDoubleClkWidth; + return mxData->mnDoubleClkWidth; } void MouseSettings::SetDoubleClickHeight( long nDoubleClkHeight ) { CopyData(); - mpData->mnDoubleClkHeight = nDoubleClkHeight; + mxData->mnDoubleClkHeight = nDoubleClkHeight; } long MouseSettings::GetDoubleClickHeight() const { - return mpData->mnDoubleClkHeight; + return mxData->mnDoubleClkHeight; } void MouseSettings::SetStartDragWidth( long nDragWidth ) { CopyData(); - mpData->mnStartDragWidth = nDragWidth; + mxData->mnStartDragWidth = nDragWidth; } long MouseSettings::GetStartDragWidth() const { - return mpData->mnStartDragWidth; + return mxData->mnStartDragWidth; } void MouseSettings::SetStartDragHeight( long nDragHeight ) { CopyData(); - mpData->mnStartDragHeight = nDragHeight; + mxData->mnStartDragHeight = nDragHeight; } long MouseSettings::GetStartDragHeight() const { - return mpData->mnStartDragHeight; + return mxData->mnStartDragHeight; } sal_uInt16 MouseSettings::GetStartDragCode() const { - return mpData->mnStartDragCode; + return mxData->mnStartDragCode; } sal_uInt16 MouseSettings::GetContextMenuCode() const { - return mpData->mnContextMenuCode; + return mxData->mnContextMenuCode; } sal_uInt16 MouseSettings::GetContextMenuClicks() const { - return mpData->mnContextMenuClicks; + return mxData->mnContextMenuClicks; } sal_uLong MouseSettings::GetScrollRepeat() const { - return mpData->mnScrollRepeat; + return mxData->mnScrollRepeat; } sal_uLong MouseSettings::GetButtonStartRepeat() const { - return mpData->mnButtonStartRepeat; + return mxData->mnButtonStartRepeat; } void MouseSettings::SetButtonRepeat( sal_uLong nRepeat ) { CopyData(); - mpData->mnButtonRepeat = nRepeat; + mxData->mnButtonRepeat = nRepeat; } sal_uLong MouseSettings::GetButtonRepeat() const { - return mpData->mnButtonRepeat; + return mxData->mnButtonRepeat; } sal_uLong MouseSettings::GetActionDelay() const { - return mpData->mnActionDelay; + return mxData->mnActionDelay; } void MouseSettings::SetMenuDelay( sal_uLong nDelay ) { CopyData(); - mpData->mnMenuDelay = nDelay; + mxData->mnMenuDelay = nDelay; } sal_uLong MouseSettings::GetMenuDelay() const { - return mpData->mnMenuDelay; + return mxData->mnMenuDelay; } void MouseSettings::SetFollow( sal_uLong nFollow ) { CopyData(); - mpData->mnFollow = nFollow; + mxData->mnFollow = nFollow; } sal_uLong MouseSettings::GetFollow() const { - return mpData->mnFollow; + return mxData->mnFollow; } void MouseSettings::SetMiddleButtonAction( sal_uInt16 nAction ) { CopyData(); - mpData->mnMiddleButtonAction = nAction; + mxData->mnMiddleButtonAction = nAction; } sal_uInt16 MouseSettings::GetMiddleButtonAction() const { - return mpData->mnMiddleButtonAction; + return mxData->mnMiddleButtonAction; } void MouseSettings::SetWheelBehavior( sal_uInt16 nBehavior ) { CopyData(); - mpData->mnWheelBehavior = nBehavior; + mxData->mnWheelBehavior = nBehavior; } sal_uInt16 MouseSettings::GetWheelBehavior() const { - return mpData->mnWheelBehavior; + return mxData->mnWheelBehavior; } bool @@ -476,7 +474,7 @@ MouseSettings::operator !=( const MouseSettings& rSet ) const } MouseSettings::MouseSettings() -: mpData(boost::make_shared<ImplMouseData>()) + : mxData(std::make_shared<ImplMouseData>()) { } @@ -487,33 +485,33 @@ MouseSettings::~MouseSettings() void MouseSettings::CopyData() { // copy if other references exist - if ( ! mpData.unique() ) { - mpData = boost::make_shared<ImplMouseData>(*mpData); + if ( ! mxData.unique() ) { + mxData = std::make_shared<ImplMouseData>(*mxData); } } bool MouseSettings::operator ==( const MouseSettings& rSet ) const { - if ( mpData == rSet.mpData ) + if ( mxData == rSet.mxData ) return true; - if ( (mpData->mnOptions == rSet.mpData->mnOptions) && - (mpData->mnDoubleClkTime == rSet.mpData->mnDoubleClkTime) && - (mpData->mnDoubleClkWidth == rSet.mpData->mnDoubleClkWidth) && - (mpData->mnDoubleClkHeight == rSet.mpData->mnDoubleClkHeight) && - (mpData->mnStartDragWidth == rSet.mpData->mnStartDragWidth) && - (mpData->mnStartDragHeight == rSet.mpData->mnStartDragHeight) && - (mpData->mnStartDragCode == rSet.mpData->mnStartDragCode) && - (mpData->mnContextMenuCode == rSet.mpData->mnContextMenuCode) && - (mpData->mnContextMenuClicks == rSet.mpData->mnContextMenuClicks) && - (mpData->mnMiddleButtonAction == rSet.mpData->mnMiddleButtonAction) && - (mpData->mnScrollRepeat == rSet.mpData->mnScrollRepeat) && - (mpData->mnButtonStartRepeat == rSet.mpData->mnButtonStartRepeat) && - (mpData->mnButtonRepeat == rSet.mpData->mnButtonRepeat) && - (mpData->mnActionDelay == rSet.mpData->mnActionDelay) && - (mpData->mnMenuDelay == rSet.mpData->mnMenuDelay) && - (mpData->mnFollow == rSet.mpData->mnFollow) && - (mpData->mnWheelBehavior == rSet.mpData->mnWheelBehavior ) ) + if ( (mxData->mnOptions == rSet.mxData->mnOptions) && + (mxData->mnDoubleClkTime == rSet.mxData->mnDoubleClkTime) && + (mxData->mnDoubleClkWidth == rSet.mxData->mnDoubleClkWidth) && + (mxData->mnDoubleClkHeight == rSet.mxData->mnDoubleClkHeight) && + (mxData->mnStartDragWidth == rSet.mxData->mnStartDragWidth) && + (mxData->mnStartDragHeight == rSet.mxData->mnStartDragHeight) && + (mxData->mnStartDragCode == rSet.mxData->mnStartDragCode) && + (mxData->mnContextMenuCode == rSet.mxData->mnContextMenuCode) && + (mxData->mnContextMenuClicks == rSet.mxData->mnContextMenuClicks) && + (mxData->mnMiddleButtonAction == rSet.mxData->mnMiddleButtonAction) && + (mxData->mnScrollRepeat == rSet.mxData->mnScrollRepeat) && + (mxData->mnButtonStartRepeat == rSet.mxData->mnButtonStartRepeat) && + (mxData->mnButtonRepeat == rSet.mxData->mnButtonRepeat) && + (mxData->mnActionDelay == rSet.mxData->mnActionDelay) && + (mxData->mnMenuDelay == rSet.mxData->mnMenuDelay) && + (mxData->mnFollow == rSet.mxData->mnFollow) && + (mxData->mnWheelBehavior == rSet.mxData->mnWheelBehavior ) ) return true; else return false; @@ -758,7 +756,7 @@ void ImplStyleData::SetStandardStyles() } StyleSettings::StyleSettings() -: mpData(boost::make_shared<ImplStyleData>()) + : mxData(std::make_shared<ImplStyleData>()) { } @@ -770,1232 +768,1232 @@ void StyleSettings::SetFaceColor( const Color& rColor ) { CopyData(); - mpData->maFaceColor = rColor; + mxData->maFaceColor = rColor; } const Color& StyleSettings::GetFaceColor() const { - return mpData->maFaceColor; + return mxData->maFaceColor; } void StyleSettings::SetCheckedColor( const Color& rColor ) { CopyData(); - mpData->maCheckedColor = rColor; + mxData->maCheckedColor = rColor; } const Color& StyleSettings::GetCheckedColor() const { - return mpData->maCheckedColor; + return mxData->maCheckedColor; } void StyleSettings::SetLightColor( const Color& rColor ) { CopyData(); - mpData->maLightColor = rColor; + mxData->maLightColor = rColor; } const Color& StyleSettings::GetLightColor() const { - return mpData->maLightColor; + return mxData->maLightColor; } void StyleSettings::SetLightBorderColor( const Color& rColor ) { CopyData(); - mpData->maLightBorderColor = rColor; + mxData->maLightBorderColor = rColor; } const Color& StyleSettings::GetLightBorderColor() const { - return mpData->maLightBorderColor; + return mxData->maLightBorderColor; } void StyleSettings::SetShadowColor( const Color& rColor ) { CopyData(); - mpData->maShadowColor = rColor; + mxData->maShadowColor = rColor; } const Color& StyleSettings::GetShadowColor() const { - return mpData->maShadowColor; + return mxData->maShadowColor; } void StyleSettings::SetDarkShadowColor( const Color& rColor ) { CopyData(); - mpData->maDarkShadowColor = rColor; + mxData->maDarkShadowColor = rColor; } const Color& StyleSettings::GetDarkShadowColor() const { - return mpData->maDarkShadowColor; + return mxData->maDarkShadowColor; } void StyleSettings::SetButtonTextColor( const Color& rColor ) { CopyData(); - mpData->maButtonTextColor = rColor; + mxData->maButtonTextColor = rColor; } const Color& StyleSettings::GetButtonTextColor() const { - return mpData->maButtonTextColor; + return mxData->maButtonTextColor; } void StyleSettings::SetButtonRolloverTextColor( const Color& rColor ) { CopyData(); - mpData->maButtonRolloverTextColor = rColor; + mxData->maButtonRolloverTextColor = rColor; } const Color& StyleSettings::GetButtonRolloverTextColor() const { - return mpData->maButtonRolloverTextColor; + return mxData->maButtonRolloverTextColor; } void StyleSettings::SetRadioCheckTextColor( const Color& rColor ) { CopyData(); - mpData->maRadioCheckTextColor = rColor; + mxData->maRadioCheckTextColor = rColor; } const Color& StyleSettings::GetRadioCheckTextColor() const { - return mpData->maRadioCheckTextColor; + return mxData->maRadioCheckTextColor; } void StyleSettings::SetGroupTextColor( const Color& rColor ) { CopyData(); - mpData->maGroupTextColor = rColor; + mxData->maGroupTextColor = rColor; } const Color& StyleSettings::GetGroupTextColor() const { - return mpData->maGroupTextColor; + return mxData->maGroupTextColor; } void StyleSettings::SetLabelTextColor( const Color& rColor ) { CopyData(); - mpData->maLabelTextColor = rColor; + mxData->maLabelTextColor = rColor; } const Color& StyleSettings::GetLabelTextColor() const { - return mpData->maLabelTextColor; + return mxData->maLabelTextColor; } void StyleSettings::SetInfoTextColor( const Color& rColor ) { CopyData(); - mpData->maInfoTextColor = rColor; + mxData->maInfoTextColor = rColor; } const Color& StyleSettings::GetInfoTextColor() const { - return mpData->maInfoTextColor; + return mxData->maInfoTextColor; } void StyleSettings::SetWindowColor( const Color& rColor ) { CopyData(); - mpData->maWindowColor = rColor; + mxData->maWindowColor = rColor; } const Color& StyleSettings::GetWindowColor() const { - return mpData->maWindowColor; + return mxData->maWindowColor; } void StyleSettings::SetWindowTextColor( const Color& rColor ) { CopyData(); - mpData->maWindowTextColor = rColor; + mxData->maWindowTextColor = rColor; } const Color& StyleSettings::GetWindowTextColor() const { - return mpData->maWindowTextColor; + return mxData->maWindowTextColor; } void StyleSettings::SetDialogColor( const Color& rColor ) { CopyData(); - mpData->maDialogColor = rColor; + mxData->maDialogColor = rColor; } const Color& StyleSettings::GetDialogColor() const { - return mpData->maDialogColor; + return mxData->maDialogColor; } void StyleSettings::SetDialogTextColor( const Color& rColor ) { CopyData(); - mpData->maDialogTextColor = rColor; + mxData->maDialogTextColor = rColor; } const Color& StyleSettings::GetDialogTextColor() const { - return mpData->maDialogTextColor; + return mxData->maDialogTextColor; } void StyleSettings::SetWorkspaceColor( const Color& rColor ) { CopyData(); - mpData->maWorkspaceColor = rColor; + mxData->maWorkspaceColor = rColor; } const Color& StyleSettings::GetWorkspaceColor() const { - return mpData->maWorkspaceColor; + return mxData->maWorkspaceColor; } void StyleSettings::SetFieldColor( const Color& rColor ) { CopyData(); - mpData->maFieldColor = rColor; + mxData->maFieldColor = rColor; } const Color& StyleSettings::GetFieldColor() const { - return mpData->maFieldColor; + return mxData->maFieldColor; } void StyleSettings::SetFieldTextColor( const Color& rColor ) { CopyData(); - mpData->maFieldTextColor = rColor; + mxData->maFieldTextColor = rColor; } const Color& StyleSettings::GetFieldTextColor() const { - return mpData->maFieldTextColor; + return mxData->maFieldTextColor; } void StyleSettings::SetFieldRolloverTextColor( const Color& rColor ) { CopyData(); - mpData->maFieldRolloverTextColor = rColor; + mxData->maFieldRolloverTextColor = rColor; } const Color& StyleSettings::GetFieldRolloverTextColor() const { - return mpData->maFieldRolloverTextColor; + return mxData->maFieldRolloverTextColor; } void StyleSettings::SetActiveColor( const Color& rColor ) { CopyData(); - mpData->maActiveColor = rColor; + mxData->maActiveColor = rColor; } const Color& StyleSettings::GetActiveColor() const { - return mpData->maActiveColor; + return mxData->maActiveColor; } void StyleSettings::SetActiveTextColor( const Color& rColor ) { CopyData(); - mpData->maActiveTextColor = rColor; + mxData->maActiveTextColor = rColor; } const Color& StyleSettings::GetActiveTextColor() const { - return mpData->maActiveTextColor; + return mxData->maActiveTextColor; } void StyleSettings::SetActiveBorderColor( const Color& rColor ) { CopyData(); - mpData->maActiveBorderColor = rColor; + mxData->maActiveBorderColor = rColor; } const Color& StyleSettings::GetActiveBorderColor() const { - return mpData->maActiveBorderColor; + return mxData->maActiveBorderColor; } void StyleSettings::SetDeactiveColor( const Color& rColor ) { CopyData(); - mpData->maDeactiveColor = rColor; + mxData->maDeactiveColor = rColor; } const Color& StyleSettings::GetDeactiveColor() const { - return mpData->maDeactiveColor; + return mxData->maDeactiveColor; } void StyleSettings::SetDeactiveTextColor( const Color& rColor ) { CopyData(); - mpData->maDeactiveTextColor = rColor; + mxData->maDeactiveTextColor = rColor; } const Color& StyleSettings::GetDeactiveTextColor() const { - return mpData->maDeactiveTextColor; + return mxData->maDeactiveTextColor; } void StyleSettings::SetDeactiveBorderColor( const Color& rColor ) { CopyData(); - mpData->maDeactiveBorderColor = rColor; + mxData->maDeactiveBorderColor = rColor; } const Color& StyleSettings::GetDeactiveBorderColor() const { - return mpData->maDeactiveBorderColor; + return mxData->maDeactiveBorderColor; } void StyleSettings::SetHighlightColor( const Color& rColor ) { CopyData(); - mpData->maHighlightColor = rColor; + mxData->maHighlightColor = rColor; } const Color& StyleSettings::GetHighlightColor() const { - return mpData->maHighlightColor; + return mxData->maHighlightColor; } void StyleSettings::SetHighlightTextColor( const Color& rColor ) { CopyData(); - mpData->maHighlightTextColor = rColor; + mxData->maHighlightTextColor = rColor; } const Color& StyleSettings::GetHighlightTextColor() const { - return mpData->maHighlightTextColor; + return mxData->maHighlightTextColor; } void StyleSettings::SetDisableColor( const Color& rColor ) { CopyData(); - mpData->maDisableColor = rColor; + mxData->maDisableColor = rColor; } const Color& StyleSettings::GetDisableColor() const { - return mpData->maDisableColor; + return mxData->maDisableColor; } void StyleSettings::SetHelpColor( const Color& rColor ) { CopyData(); - mpData->maHelpColor = rColor; + mxData->maHelpColor = rColor; } const Color& StyleSettings::GetHelpColor() const { - return mpData->maHelpColor; + return mxData->maHelpColor; } void StyleSettings::SetHelpTextColor( const Color& rColor ) { CopyData(); - mpData->maHelpTextColor = rColor; + mxData->maHelpTextColor = rColor; } const Color& StyleSettings::GetHelpTextColor() const { - return mpData->maHelpTextColor; + return mxData->maHelpTextColor; } void StyleSettings::SetMenuColor( const Color& rColor ) { CopyData(); - mpData->maMenuColor = rColor; + mxData->maMenuColor = rColor; } const Color& StyleSettings::GetMenuColor() const { - return mpData->maMenuColor; + return mxData->maMenuColor; } void StyleSettings::SetMenuBarColor( const Color& rColor ) { CopyData(); - mpData->maMenuBarColor = rColor; + mxData->maMenuBarColor = rColor; } const Color& StyleSettings::GetMenuBarColor() const { - return mpData->maMenuBarColor; + return mxData->maMenuBarColor; } void StyleSettings::SetMenuBarRolloverColor( const Color& rColor ) { CopyData(); - mpData->maMenuBarRolloverColor = rColor; + mxData->maMenuBarRolloverColor = rColor; } const Color& StyleSettings::GetMenuBarRolloverColor() const { - return mpData->maMenuBarRolloverColor; + return mxData->maMenuBarRolloverColor; } void StyleSettings::SetMenuBorderColor( const Color& rColor ) { CopyData(); - mpData->maMenuBorderColor = rColor; + mxData->maMenuBorderColor = rColor; ... etc. - the rest is truncated
_______________________________________________ Libreoffice-commits mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
