From 4c8962588e4d31ddc96aa302d612b921374c71b7 Mon Sep 17 00:00:00 2001 From: wmtan Date: Sat, 26 Nov 2016 01:09:40 +0100 Subject: [PATCH] Use make_shared --- Fireworks/Core/interface/CmsShowCommonPopup.h | 4 +- Fireworks/Core/interface/CmsShowViewPopup.h | 4 +- Fireworks/Core/interface/FWEvePtr.h | 4 +- Fireworks/Core/interface/FWEveView.h | 2 +- Fireworks/Core/interface/FWEveViewManager.h | 10 ++--- Fireworks/Core/interface/FWEventItem.h | 6 +-- .../Core/interface/FWEventItemsManager.h | 4 +- Fireworks/Core/interface/FWGUIManager.h | 1 - .../Core/interface/FWGeometryTableViewBase.h | 4 +- .../interface/FWGeometryTableViewManager.h | 2 +- Fireworks/Core/interface/FWHLTValidator.h | 2 +- .../Core/interface/FWItemAccessorFactory.h | 4 +- .../Core/interface/FWParameterSetterBase.h | 4 +- .../interface/FWProxyBuilderConfiguration.h | 4 +- Fireworks/Core/interface/FWTableViewManager.h | 2 +- .../interface/FWTriggerTableViewManager.h | 2 +- .../Core/interface/FWTypeToRepresentations.h | 6 +-- .../Core/interface/FWViewEnergyScaleEditor.h | 4 +- .../Core/interface/FWViewManagerManager.h | 6 +-- Fireworks/Core/src/CmsShowCommonPopup.cc | 2 +- Fireworks/Core/src/CmsShowMain.h | 1 - Fireworks/Core/src/CmsShowMainBase.cc | 8 ++-- Fireworks/Core/src/CmsShowViewPopup.cc | 2 +- .../src/FWCollectionSummaryTableManager.h | 2 +- Fireworks/Core/src/FWColorManager.cc | 6 +-- Fireworks/Core/src/FWEveViewManager.cc | 12 +++--- Fireworks/Core/src/FWEventItem.cc | 2 +- Fireworks/Core/src/FWExpressionValidator.cc | 38 +++++++++---------- Fireworks/Core/src/FWExpressionValidator.h | 8 ++-- .../Core/src/FWGUIValidatingTextEntry.cc | 2 +- Fireworks/Core/src/FWGUIValidatingTextEntry.h | 4 +- Fireworks/Core/src/FWGeometryTableView.cc | 8 ++-- Fireworks/Core/src/FWGeometryTableView.h | 2 +- .../Core/src/FWGeometryTableViewManager.cc | 8 ++-- Fireworks/Core/src/FWHLTValidator.cc | 4 +- Fireworks/Core/src/FWItemAccessorFactory.cc | 18 ++++----- .../FWItemTVirtualCollectionProxyAccessor.cc | 2 +- .../FWItemTVirtualCollectionProxyAccessor.h | 6 +-- Fireworks/Core/src/FWModelChangeManager.cc | 6 +-- Fireworks/Core/src/FWParameterSetterBase.cc | 4 +- .../Core/src/FWProxyBuilderConfiguration.cc | 2 +- Fireworks/Core/src/FWRPZView.cc | 4 +- .../Core/src/FWSimpleRepresentationChecker.cc | 2 +- Fireworks/Core/src/FWTableView.cc | 2 +- Fireworks/Core/src/FWTableViewManager.cc | 2 +- .../Core/src/FWTriggerTableViewManager.cc | 12 +++--- Fireworks/Core/src/FWTypeToRepresentations.cc | 6 +-- Fireworks/Core/src/FWValidatorBase.h | 4 +- Fireworks/Core/src/FWViewEnergyScaleEditor.cc | 4 +- Fireworks/Core/src/FWViewManagerManager.cc | 6 +-- Fireworks/Core/test/unittest_changemanager.cc | 2 +- .../test/unittest_modelexpressionselector.cc | 2 +- Fireworks/Core/test/unittest_modelfilter.cc | 2 +- .../Core/test/unittest_selectionmanager.cc | 2 +- 54 files changed, 134 insertions(+), 138 deletions(-) diff --git a/Fireworks/Core/interface/CmsShowCommonPopup.h b/Fireworks/Core/interface/CmsShowCommonPopup.h index c50e6d7e3ab11..5db90554ac780 100644 --- a/Fireworks/Core/interface/CmsShowCommonPopup.h +++ b/Fireworks/Core/interface/CmsShowCommonPopup.h @@ -2,7 +2,7 @@ #define Fireworks_Core_CmsShowCommonPopup_h #ifndef __CINT__ -#include +#include #endif #include "GuiTypes.h" #include "TGFrame.h" @@ -64,7 +64,7 @@ class CmsShowCommonPopup : public TGTransientFrame, FWColorSelect* m_colorSelectWidget[kFWGeomColorSize]; FWColorSelect* m_colorRnrCtxHighlightWidget; FWColorSelect* m_colorRnrCtxSelectWidget; - std::vector > m_setters; + std::vector > m_setters; #endif TGComboBox *m_combo; }; diff --git a/Fireworks/Core/interface/CmsShowViewPopup.h b/Fireworks/Core/interface/CmsShowViewPopup.h index 9110fc3a65a1d..6654a80a19a88 100644 --- a/Fireworks/Core/interface/CmsShowViewPopup.h +++ b/Fireworks/Core/interface/CmsShowViewPopup.h @@ -21,7 +21,7 @@ // system include files #include #ifndef __CINT__ -#include +#include #include #endif #include "TGFrame.h" @@ -66,7 +66,7 @@ class ViewerParameterGUI : public TGCompositeFrame, TGTab* m_tab; std::string m_selectedTabName; #ifndef __CINT__ - std::vector > m_setters; + std::vector > m_setters; #endif }; diff --git a/Fireworks/Core/interface/FWEvePtr.h b/Fireworks/Core/interface/FWEvePtr.h index 153005d909600..1a859a80eba66 100644 --- a/Fireworks/Core/interface/FWEvePtr.h +++ b/Fireworks/Core/interface/FWEvePtr.h @@ -19,7 +19,7 @@ // // system include files -#include +#include #include "TEveElement.h" // user include files @@ -76,7 +76,7 @@ class FWEvePtr { //const FWEvePtr& operator=(const FWEvePtr&); // stop default // ---------- member data -------------------------------- - boost::shared_ptr m_container; + std::shared_ptr m_container; }; diff --git a/Fireworks/Core/interface/FWEveView.h b/Fireworks/Core/interface/FWEveView.h index f5e715bc7e672..cb7d64fc19978 100644 --- a/Fireworks/Core/interface/FWEveView.h +++ b/Fireworks/Core/interface/FWEveView.h @@ -145,7 +145,7 @@ class FWEveView : public FWViewBase FWBoolParameter m_showCameraGuide; FWBoolParameter m_useGlobalEnergyScale; - boost::shared_ptr m_viewContextMenu; + std::shared_ptr m_viewContextMenu; std::auto_ptr m_viewContext; std::auto_ptr m_localEnergyScale; diff --git a/Fireworks/Core/interface/FWEveViewManager.h b/Fireworks/Core/interface/FWEveViewManager.h index 49f643aaf7ab8..63d7684d74525 100644 --- a/Fireworks/Core/interface/FWEveViewManager.h +++ b/Fireworks/Core/interface/FWEveViewManager.h @@ -22,7 +22,7 @@ #include #include #include -#include +#include // user include files #include "Fireworks/Core/interface/FWViewManagerBase.h" @@ -88,7 +88,7 @@ class FWEveViewManager : public FWViewManagerBase const FWEveViewManager& operator=(const FWEveViewManager&); // stop default FWViewBase* buildView(TEveWindowSlot* iParent, const std::string& type); - FWEveView* finishViewCreate (boost::shared_ptr); + FWEveView* finishViewCreate (std::shared_ptr); void beingDestroyed(const FWViewBase*); void modelChanges(const FWModelIds& iIds); @@ -99,9 +99,9 @@ class FWEveViewManager : public FWViewManagerBase // ---------- member data -------------------------------- typedef std::map > TypeToBuilder; - typedef std::vector > BuilderVec; + typedef std::vector > BuilderVec; typedef BuilderVec::iterator BuilderVec_it; - typedef std::vector >::iterator EveViewVec_it; + typedef std::vector >::iterator EveViewVec_it; TypeToBuilder m_typeToBuilder; @@ -109,7 +109,7 @@ class FWEveViewManager : public FWViewManagerBase std::map m_builders; // key is viewer bit - std::vector< std::vector > > m_views; + std::vector< std::vector > > m_views; std::map m_interactionLists; }; diff --git a/Fireworks/Core/interface/FWEventItem.h b/Fireworks/Core/interface/FWEventItem.h index 17696cc826b4b..aabce423394f3 100644 --- a/Fireworks/Core/interface/FWEventItem.h +++ b/Fireworks/Core/interface/FWEventItem.h @@ -22,7 +22,7 @@ #include #include #include "FWCore/Utilities/interface/TypeWithDict.h" -#include +#include #include // user include files @@ -75,7 +75,7 @@ class FWEventItem FWEventItem(fireworks::Context* iContext, unsigned int iItemId, - boost::shared_ptr iAccessor, + std::shared_ptr iAccessor, const FWPhysicsObjectDesc& iDesc, const FWConfiguration* pbConf = 0); virtual ~FWEventItem(); @@ -231,7 +231,7 @@ class FWEventItem std::string m_name; const TClass* m_type; std::string m_purpose; - boost::shared_ptr m_accessor; + std::shared_ptr m_accessor; FWDisplayProperties m_displayProperties; int m_layer; mutable std::vector m_itemInfos; diff --git a/Fireworks/Core/interface/FWEventItemsManager.h b/Fireworks/Core/interface/FWEventItemsManager.h index 7ed2203d376a3..a7e138efa95af 100644 --- a/Fireworks/Core/interface/FWEventItemsManager.h +++ b/Fireworks/Core/interface/FWEventItemsManager.h @@ -20,7 +20,7 @@ // system include files #include -#include +#include #include "sigc++/signal.h" // user include files @@ -86,7 +86,7 @@ class FWEventItemsManager : public FWConfigurable fireworks::Context* m_context; const edm::EventBase* m_event; - boost::shared_ptr m_accessorFactory; + std::shared_ptr m_accessorFactory; }; diff --git a/Fireworks/Core/interface/FWGUIManager.h b/Fireworks/Core/interface/FWGUIManager.h index d9294a76237f1..0e74debaba95a 100644 --- a/Fireworks/Core/interface/FWGUIManager.h +++ b/Fireworks/Core/interface/FWGUIManager.h @@ -21,7 +21,6 @@ // system include files #include #include -#include #include #include "Rtypes.h" #include "GuiTypes.h" diff --git a/Fireworks/Core/interface/FWGeometryTableViewBase.h b/Fireworks/Core/interface/FWGeometryTableViewBase.h index ad1862b10d7b1..ee7244a0e87aa 100644 --- a/Fireworks/Core/interface/FWGeometryTableViewBase.h +++ b/Fireworks/Core/interface/FWGeometryTableViewBase.h @@ -2,7 +2,7 @@ #define Fireworks_Core_FWGeometryTableViewBase_h #ifndef __CINT__ -#include +#include #endif @@ -140,7 +140,7 @@ class FWGeometryTableViewBase TEveScene* m_eveScene; #ifndef __CINT__ - // std::vector > m_setters; + // std::vector > m_setters; #endif // void resetSetters(); // void makeSetter(TGCompositeFrame* frame, FWParameterBase* param); diff --git a/Fireworks/Core/interface/FWGeometryTableViewManager.h b/Fireworks/Core/interface/FWGeometryTableViewManager.h index 1d018c4dd8514..9be75d49fb73e 100644 --- a/Fireworks/Core/interface/FWGeometryTableViewManager.h +++ b/Fireworks/Core/interface/FWGeometryTableViewManager.h @@ -50,7 +50,7 @@ class FWGeometryTableViewManager : public FWViewManagerBase virtual void modelChangesComing() {} virtual void modelChangesDone() {} - std::vector > m_views; + std::vector > m_views; private: FWGeometryTableViewManager(const FWGeometryTableViewManager&); // stop default diff --git a/Fireworks/Core/interface/FWHLTValidator.h b/Fireworks/Core/interface/FWHLTValidator.h index 3b3a7b702cb09..654298dacf8f9 100644 --- a/Fireworks/Core/interface/FWHLTValidator.h +++ b/Fireworks/Core/interface/FWHLTValidator.h @@ -20,7 +20,7 @@ class FWHLTValidator: public FWValidatorBase { void setProcess(const char* x) { m_process = x; m_triggerNames.clear(); } virtual void fillOptions(const char* iBegin, const char* iEnd, - std::vector, std::string> >& oOptions) const; + std::vector, std::string> >& oOptions) const; private: FWHLTValidator(const FWHLTValidator&); // stop default const FWHLTValidator& operator=(const FWHLTValidator&); // stop default diff --git a/Fireworks/Core/interface/FWItemAccessorFactory.h b/Fireworks/Core/interface/FWItemAccessorFactory.h index d459bdd4d0029..6f35353529bc6 100644 --- a/Fireworks/Core/interface/FWItemAccessorFactory.h +++ b/Fireworks/Core/interface/FWItemAccessorFactory.h @@ -19,7 +19,7 @@ // // system include files -#include +#include #include // user include files @@ -35,7 +35,7 @@ class FWItemAccessorFactory { virtual ~FWItemAccessorFactory(); // ---------- const member functions --------------------- - boost::shared_ptr accessorFor(const TClass*) const; + std::shared_ptr accessorFor(const TClass*) const; static bool hasAccessor(const TClass *iClass, std::string &result); static bool hasTVirtualCollectionProxy(const TClass *iClass); static bool hasMemberTVirtualCollectionProxy(const TClass *iClass, diff --git a/Fireworks/Core/interface/FWParameterSetterBase.h b/Fireworks/Core/interface/FWParameterSetterBase.h index 0d47a4ea93509..7085df392bdc4 100644 --- a/Fireworks/Core/interface/FWParameterSetterBase.h +++ b/Fireworks/Core/interface/FWParameterSetterBase.h @@ -19,7 +19,7 @@ // // system include files -#include +#include // user include files @@ -38,7 +38,7 @@ class FWParameterSetterBase // ---------- static member functions -------------------- - static boost::shared_ptr makeSetterFor(FWParameterBase*); + static std::shared_ptr makeSetterFor(FWParameterBase*); // ---------- member functions --------------------------- diff --git a/Fireworks/Core/interface/FWProxyBuilderConfiguration.h b/Fireworks/Core/interface/FWProxyBuilderConfiguration.h index fa4c040d4a42d..046e2ea5d3f4f 100644 --- a/Fireworks/Core/interface/FWProxyBuilderConfiguration.h +++ b/Fireworks/Core/interface/FWProxyBuilderConfiguration.h @@ -28,7 +28,7 @@ #include "Fireworks/Core/interface/FWGenericParameterWithRange.h" #ifndef __CINT__ -#include +#include #include #endif @@ -64,7 +64,7 @@ class FWProxyBuilderConfiguration : public FWConfigurableParameterizable, const FWEventItem* m_item; #ifndef __CINT__ - std::vector > m_setters; + std::vector > m_setters; #endif }; diff --git a/Fireworks/Core/interface/FWTableViewManager.h b/Fireworks/Core/interface/FWTableViewManager.h index 963dfca692e41..56a5e0e37c6b5 100644 --- a/Fireworks/Core/interface/FWTableViewManager.h +++ b/Fireworks/Core/interface/FWTableViewManager.h @@ -88,7 +88,7 @@ class FWTableViewManager : public FWViewManagerBase, public FWConfigurable virtual void colorsChanged(); void dataChanged (); - typedef std::vector > Views; + typedef std::vector > Views; Views m_views; Items m_items; diff --git a/Fireworks/Core/interface/FWTriggerTableViewManager.h b/Fireworks/Core/interface/FWTriggerTableViewManager.h index 3a9173fd21594..f16bdf0b0fca0 100644 --- a/Fireworks/Core/interface/FWTriggerTableViewManager.h +++ b/Fireworks/Core/interface/FWTriggerTableViewManager.h @@ -48,7 +48,7 @@ class FWTriggerTableViewManager : public FWViewManagerBase, public FWConfigurabl void updateProcessList(); - std::vector > m_views; + std::vector > m_views; private: FWTriggerTableViewManager(const FWTriggerTableViewManager&); // stop default diff --git a/Fireworks/Core/interface/FWTypeToRepresentations.h b/Fireworks/Core/interface/FWTypeToRepresentations.h index ef53f72e94e90..27634d9968874 100644 --- a/Fireworks/Core/interface/FWTypeToRepresentations.h +++ b/Fireworks/Core/interface/FWTypeToRepresentations.h @@ -22,7 +22,7 @@ #include #include #include -#include +#include // user include files #include "Fireworks/Core/interface/FWRepresentationInfo.h" @@ -42,7 +42,7 @@ class FWTypeToRepresentations { // ---------- static member functions -------------------- // ---------- member functions --------------------------- - void add( boost::shared_ptr iChecker); + void add( std::shared_ptr iChecker); void insert( const FWTypeToRepresentations& ); private: @@ -52,7 +52,7 @@ class FWTypeToRepresentations { // ---------- member data -------------------------------- mutable std::map > m_typeToReps; - std::vector > m_checkers; + std::vector > m_checkers; }; diff --git a/Fireworks/Core/interface/FWViewEnergyScaleEditor.h b/Fireworks/Core/interface/FWViewEnergyScaleEditor.h index cca82fecc6aaa..9c3386fb15495 100644 --- a/Fireworks/Core/interface/FWViewEnergyScaleEditor.h +++ b/Fireworks/Core/interface/FWViewEnergyScaleEditor.h @@ -22,7 +22,7 @@ // user include files #ifndef __CINT__ -#include +#include #endif #include "TGFrame.h" #include "Fireworks/Core/interface/FWParameterSetterEditorBase.h" @@ -61,7 +61,7 @@ class FWViewEnergyScaleEditor : public TGVerticalFrame, public FWParameterSetter bool m_enabled; #ifndef __CINT__ - std::vector > m_setters; + std::vector > m_setters; #endif }; diff --git a/Fireworks/Core/interface/FWViewManagerManager.h b/Fireworks/Core/interface/FWViewManagerManager.h index aa13dec6699db..e94a0304e98ea 100644 --- a/Fireworks/Core/interface/FWViewManagerManager.h +++ b/Fireworks/Core/interface/FWViewManagerManager.h @@ -21,7 +21,7 @@ // system include files #include #include -#include +#include #include #include @@ -47,7 +47,7 @@ class FWViewManagerManager // ---------- static member functions -------------------- // ---------- member functions --------------------------- - void add( boost::shared_ptr); + void add( std::shared_ptr); void registerEventItem(const FWEventItem*iItem); void removeEventItem(const FWEventItem*iItem); void eventBegin(); @@ -59,7 +59,7 @@ class FWViewManagerManager const FWViewManagerManager& operator=(const FWViewManagerManager&); // stop default // ---------- member data -------------------------------- - std::vector > m_viewManagers; + std::vector > m_viewManagers; FWModelChangeManager* m_changeManager; FWColorManager* m_colorManager; std::map m_typeToItems; //use this to tell view managers registered after the item diff --git a/Fireworks/Core/src/CmsShowCommonPopup.cc b/Fireworks/Core/src/CmsShowCommonPopup.cc index e87079d70181c..631889be61ebb 100644 --- a/Fireworks/Core/src/CmsShowCommonPopup.cc +++ b/Fireworks/Core/src/CmsShowCommonPopup.cc @@ -337,7 +337,7 @@ void CmsShowCommonPopup::getColorSetColors (int& hci, int& sci) TGFrame* CmsShowCommonPopup::makeSetter(TGCompositeFrame* frame, FWParameterBase* param) { - boost::shared_ptr ptr( FWParameterSetterBase::makeSetterFor(param) ); + std::shared_ptr ptr( FWParameterSetterBase::makeSetterFor(param) ); ptr->attach(param, this); TGFrame* pframe = ptr->build(frame); diff --git a/Fireworks/Core/src/CmsShowMain.h b/Fireworks/Core/src/CmsShowMain.h index 7927c3c2bfef5..50872ef84d820 100644 --- a/Fireworks/Core/src/CmsShowMain.h +++ b/Fireworks/Core/src/CmsShowMain.h @@ -26,7 +26,6 @@ #include #include #include -#include #include "Rtypes.h" diff --git a/Fireworks/Core/src/CmsShowMainBase.cc b/Fireworks/Core/src/CmsShowMainBase.cc index da6f86bb34022..3e592f662b3b7 100644 --- a/Fireworks/Core/src/CmsShowMainBase.cc +++ b/Fireworks/Core/src/CmsShowMainBase.cc @@ -111,22 +111,22 @@ CmsShowMainBase::setupViewManagers() { guiManager()->updateStatus("Setting up view manager..."); - boost::shared_ptr eveViewManager(new FWEveViewManager(guiManager())); + std::shared_ptr eveViewManager = std::make_shared(guiManager()); eveViewManager->setContext(m_contextPtr); viewManager()->add(eveViewManager); - boost::shared_ptr tableViewManager(new FWTableViewManager(guiManager())); + auto tableViewManager = std::make_shared(guiManager()); configurationManager()->add(std::string("Tables"), tableViewManager.get()); viewManager()->add(tableViewManager); eiManager()->goingToClearItems_.connect(boost::bind(&FWTableViewManager::removeAllItems, tableViewManager.get())); - boost::shared_ptr triggerTableViewManager(new FWTriggerTableViewManager(guiManager())); + auto triggerTableViewManager = std::make_shared(guiManager()); configurationManager()->add(std::string("TriggerTables"), triggerTableViewManager.get()); configurationManager()->add(std::string("L1TriggerTables"), triggerTableViewManager.get()); // AMT: added for backward compatibilty triggerTableViewManager->setContext(m_contextPtr); viewManager()->add(triggerTableViewManager); - boost::shared_ptr geoTableViewManager(new FWGeometryTableViewManager(guiManager(), m_simGeometryFilename)); + auto geoTableViewManager = std::make_shared(guiManager(), m_simGeometryFilename); geoTableViewManager->setContext(m_contextPtr); viewManager()->add(geoTableViewManager); diff --git a/Fireworks/Core/src/CmsShowViewPopup.cc b/Fireworks/Core/src/CmsShowViewPopup.cc index b8bb4d129b748..6229a5a88b5e7 100644 --- a/Fireworks/Core/src/CmsShowViewPopup.cc +++ b/Fireworks/Core/src/CmsShowViewPopup.cc @@ -245,7 +245,7 @@ ViewerParameterGUI::requestTab(const char* name) ViewerParameterGUI& ViewerParameterGUI::addParam( const FWParameterBase* param) { - boost::shared_ptr ptr( FWParameterSetterBase::makeSetterFor((FWParameterBase*)param) ); + std::shared_ptr ptr( FWParameterSetterBase::makeSetterFor((FWParameterBase*)param) ); ptr->attach((FWParameterBase*)param, this); TGCompositeFrame* parent = m_tab->GetCurrentContainer(); diff --git a/Fireworks/Core/src/FWCollectionSummaryTableManager.h b/Fireworks/Core/src/FWCollectionSummaryTableManager.h index 9435f6f224050..9e5a0376c59f3 100644 --- a/Fireworks/Core/src/FWCollectionSummaryTableManager.h +++ b/Fireworks/Core/src/FWCollectionSummaryTableManager.h @@ -20,7 +20,7 @@ // system include files #include -#include +#include // user include files #include "Fireworks/TableWidget/interface/FWTableManagerBase.h" diff --git a/Fireworks/Core/src/FWColorManager.cc b/Fireworks/Core/src/FWColorManager.cc index 284999de557d7..3e27c953543c6 100644 --- a/Fireworks/Core/src/FWColorManager.cc +++ b/Fireworks/Core/src/FWColorManager.cc @@ -13,7 +13,7 @@ // system include files #include #include -#include +#include #include "TColor.h" #include "TROOT.h" #include "TMath.h" @@ -325,7 +325,7 @@ FWColorManager::geomColor(FWGeomColorIndex iIndex) const } -static boost::shared_ptr > m_oldColorToIndexMap; +static std::shared_ptr > m_oldColorToIndexMap; Color_t FWColorManager::oldColorToIndex(Color_t iColor, int version) const @@ -343,7 +343,7 @@ FWColorManager::oldColorToIndex(Color_t iColor, int version) const if (version < 3) { if(0==m_oldColorToIndexMap.get()) { - m_oldColorToIndexMap = boost::shared_ptr >(new std::map()); + m_oldColorToIndexMap = std::make_shared >(); (*m_oldColorToIndexMap)[kRed]=kFWRed; (*m_oldColorToIndexMap)[kBlue]=kFWBlue; (*m_oldColorToIndexMap)[kYellow]=kFWYellow; diff --git a/Fireworks/Core/src/FWEveViewManager.cc b/Fireworks/Core/src/FWEveViewManager.cc index f52c39a911ee1..0bd9498049f3f 100644 --- a/Fireworks/Core/src/FWEveViewManager.cc +++ b/Fireworks/Core/src/FWEveViewManager.cc @@ -241,7 +241,7 @@ FWEveViewManager::newItem(const FWEventItem* iItem) // 2. // printf("FWEveViewManager::makeProxyBuilderFor NEW builder %s \n", builderName.c_str()); - boost::shared_ptr pB(builder); + std::shared_ptr pB(builder); builder->setItem(iItem); iItem->changed_.connect(boost::bind(&FWEveViewManager::modelChanges,this,_1)); iItem->goingToBeDestroyed_.connect(boost::bind(&FWEveViewManager::removeItem,this,_1)); @@ -310,7 +310,7 @@ FWEveViewManager::buildView(TEveWindowSlot* iParent, const std::string& viewName } } - boost::shared_ptr view; + std::shared_ptr view; switch(type) { case FWViewType::k3D: @@ -338,12 +338,12 @@ FWEveViewManager::buildView(TEveWindowSlot* iParent, const std::string& viewName break; } - m_views[type].push_back(boost::shared_ptr (view)); + m_views[type].push_back(std::shared_ptr (view)); return finishViewCreate(m_views[type].back()); } FWEveView* -FWEveViewManager::finishViewCreate(boost::shared_ptr view) +FWEveViewManager::finishViewCreate(std::shared_ptr view) { // printf("new view %s added \n", view->typeName().c_str()); gEve->DisableRedraw(); @@ -804,11 +804,11 @@ FWEveViewManager::supportedTypesAndRepresentations() const info.classType(name, isSimple); if(isSimple) { - returnValue.add(boost::shared_ptr(new FWSimpleRepresentationChecker(name, it->first,bitPackedViews,representsSubPart, FFOnly)) ); + returnValue.add(std::make_shared(name, it->first,bitPackedViews,representsSubPart, FFOnly) ); } else { - returnValue.add(boost::shared_ptr(new FWEDProductRepresentationChecker(name, it->first,bitPackedViews,representsSubPart, FFOnly)) ); + returnValue.add(std::make_shared(name, it->first,bitPackedViews,representsSubPart, FFOnly) ); } } } diff --git a/Fireworks/Core/src/FWEventItem.cc b/Fireworks/Core/src/FWEventItem.cc index f58b4826e0b65..578db794d1d29 100644 --- a/Fireworks/Core/src/FWEventItem.cc +++ b/Fireworks/Core/src/FWEventItem.cc @@ -51,7 +51,7 @@ int FWEventItem::maxLayerValue() // FWEventItem::FWEventItem(fireworks::Context* iContext, unsigned int iId, - boost::shared_ptr iAccessor, + std::shared_ptr iAccessor, const FWPhysicsObjectDesc& iDesc, const FWConfiguration* pbc) : m_context(iContext), m_id(iId), diff --git a/Fireworks/Core/src/FWExpressionValidator.cc b/Fireworks/Core/src/FWExpressionValidator.cc index 63c2b92453d69..a5ba7cc501e90 100644 --- a/Fireworks/Core/src/FWExpressionValidator.cc +++ b/Fireworks/Core/src/FWExpressionValidator.cc @@ -25,7 +25,7 @@ // // constants, enums and typedefs // -typedef std::vector > Options; +typedef std::vector > Options; namespace fireworks { template< class T> @@ -60,14 +60,14 @@ namespace fireworks { unsigned long substitutionEnd() const { return m_endOfName; } - const std::vector >& options() const { + const std::vector >& options() const { if(m_hasSubOptions && m_subOptions.empty()) { fillOptionForType(m_type, m_subOptions); std::sort(m_subOptions.begin(),m_subOptions.end(), - fireworks::OptionNodePtrCompare >()); - std::vector >::iterator it= + fireworks::OptionNodePtrCompare >()); + std::vector >::iterator it= std::unique(m_subOptions.begin(),m_subOptions.end(), - fireworks::OptionNodePtrEqual >()); + fireworks::OptionNodePtrEqual >()); m_subOptions.erase(it, m_subOptions.end()); m_hasSubOptions = !m_subOptions.empty(); @@ -80,12 +80,12 @@ namespace fireworks { } static void fillOptionForType( const edm::TypeWithDict&, - std::vector >& ); + std::vector >& ); private: edm::TypeWithDict m_type; mutable std::string m_description; mutable std::string::size_type m_endOfName; - mutable std::vector > m_subOptions; + mutable std::vector > m_subOptions; mutable bool m_hasSubOptions; static bool typeHasOptions(const edm::TypeWithDict& iType); }; @@ -124,7 +124,7 @@ namespace fireworks { void OptionNode::fillOptionForType( const edm::TypeWithDict& iType, - std::vector >& oOptions) + std::vector >& oOptions) { edm::TypeWithDict type = iType; if(type.isPointer()) { @@ -141,7 +141,7 @@ namespace fireworks { m.isOperator() || !m.isPublic() || m.name().substr(0,2)=="__") {continue;} - oOptions.push_back(boost::shared_ptr(new OptionNode(m))); + oOptions.push_back(std::make_shared(m)); } edm::TypeBases bases(type); @@ -164,10 +164,10 @@ namespace fireworks { // constructors and destructor // #define FUN1(_fun_) \ - m_builtins.push_back(boost::shared_ptr( new OptionNode( # _fun_ "(float):float", strlen( # _fun_ )+1,s_float))) + m_builtins.push_back(std::make_shared( # _fun_ "(float):float", strlen( # _fun_ )+1,s_float)) #define FUN2(_fun_) \ - m_builtins.push_back(boost::shared_ptr( new OptionNode( # _fun_ "(float,float):float", strlen( # _fun_ )+1,s_float))) + m_builtins.push_back(std::make_shared( # _fun_ "(float,float):float", strlen( # _fun_ )+1,s_float)) FWExpressionValidator::FWExpressionValidator() { @@ -193,7 +193,7 @@ FWExpressionValidator::FWExpressionValidator() FUN2(min); FUN2(max); std::sort(m_builtins.begin(),m_builtins.end(), - fireworks::OptionNodePtrCompare >()); + fireworks::OptionNodePtrCompare >()); } @@ -230,10 +230,10 @@ FWExpressionValidator::setType(const edm::TypeWithDict& iType) m_options=m_builtins; OptionNode::fillOptionForType(iType, m_options); std::sort(m_options.begin(),m_options.end(), - fireworks::OptionNodePtrCompare >()); - std::vector >::iterator it= + fireworks::OptionNodePtrCompare >()); + std::vector >::iterator it= std::unique(m_options.begin(),m_options.end(), - fireworks::OptionNodePtrEqual >()); + fireworks::OptionNodePtrEqual >()); m_options.erase(it, m_options.end()); } @@ -272,7 +272,7 @@ namespace { void FWExpressionValidator::fillOptions(const char* iBegin, const char* iEnd, - std::vector, std::string> >& oOptions) const + std::vector, std::string> >& oOptions) const { using fireworks::OptionNode; oOptions.clear(); @@ -287,11 +287,11 @@ FWExpressionValidator::fillOptions(const char* iBegin, const char* iEnd, *it-begin, edm::TypeWithDict()); - boost::shared_ptr comp(&temp, dummyDelete); + std::shared_ptr comp(&temp, dummyDelete); Options::const_iterator itFind =std::lower_bound(nodes->begin(), nodes->end(), comp, - fireworks::OptionNodePtrCompare >()); + fireworks::OptionNodePtrCompare >()); if(itFind == nodes->end() || *comp < *(*itFind) ) { //no match so we have an error @@ -308,7 +308,7 @@ FWExpressionValidator::fillOptions(const char* iBegin, const char* iEnd, it != itEnd; ++it) { if(part == (*it)->description().substr(0,part_size) ) { - oOptions.push_back(std::make_pair(boost::shared_ptr(const_cast(&((*it)->description())), dummyDelete), + oOptions.push_back(std::make_pair(std::shared_ptr(const_cast(&((*it)->description())), dummyDelete), (*it)->description().substr(part_size,(*it)->substitutionEnd()-part_size))); } } diff --git a/Fireworks/Core/src/FWExpressionValidator.h b/Fireworks/Core/src/FWExpressionValidator.h index 0001d5658a318..cc4af26fbc7cb 100644 --- a/Fireworks/Core/src/FWExpressionValidator.h +++ b/Fireworks/Core/src/FWExpressionValidator.h @@ -20,7 +20,7 @@ // system include files #include -#include +#include #include "FWCore/Utilities/interface/TypeWithDict.h" // user include files @@ -39,7 +39,7 @@ class FWExpressionValidator : public FWValidatorBase { // ---------- const member functions --------------------- virtual void fillOptions(const char* iBegin, const char* iEnd, - std::vector, std::string> >& oOptions) const; + std::vector, std::string> >& oOptions) const; // ---------- static member functions -------------------- @@ -53,8 +53,8 @@ class FWExpressionValidator : public FWValidatorBase { // ---------- member data -------------------------------- edm::TypeWithDict m_type; - std::vector > m_options; - std::vector > m_builtins; + std::vector > m_options; + std::vector > m_builtins; }; diff --git a/Fireworks/Core/src/FWGUIValidatingTextEntry.cc b/Fireworks/Core/src/FWGUIValidatingTextEntry.cc index 3d991ab95384a..8382e32ae57fa 100644 --- a/Fireworks/Core/src/FWGUIValidatingTextEntry.cc +++ b/Fireworks/Core/src/FWGUIValidatingTextEntry.cc @@ -165,7 +165,7 @@ FWGUIValidatingTextEntry::showOptions() { std::string subText(text,text+GetCursorPosition()); //std::cout <, std::string> > Options; + typedef std::vector, std::string> > Options; m_validator->fillOptions(text, text+GetCursorPosition(), m_options); if(m_options.empty()) { return;} if(m_options.size()==1) { diff --git a/Fireworks/Core/src/FWGUIValidatingTextEntry.h b/Fireworks/Core/src/FWGUIValidatingTextEntry.h index 7d21357f511bb..79ce8098f6c5c 100644 --- a/Fireworks/Core/src/FWGUIValidatingTextEntry.h +++ b/Fireworks/Core/src/FWGUIValidatingTextEntry.h @@ -22,7 +22,7 @@ #include #include #ifndef __CINT__ -#include +#include #endif // user include files #include "TGTextEntry.h" @@ -70,7 +70,7 @@ class FWGUIValidatingTextEntry : public TGTextEntry { UInt_t m_listHeight; #ifndef __CINT__ - std::vector, std::string> > m_options; + std::vector, std::string> > m_options; #endif }; diff --git a/Fireworks/Core/src/FWGeometryTableView.cc b/Fireworks/Core/src/FWGeometryTableView.cc index 0bc2c20f2bd0a..76cb7ee86b0a5 100644 --- a/Fireworks/Core/src/FWGeometryTableView.cc +++ b/Fireworks/Core/src/FWGeometryTableView.cc @@ -87,7 +87,7 @@ class FWGeoMaterialValidator : public FWValidatorBase } - virtual void fillOptions(const char* iBegin, const char* iEnd, std::vector, std::string> >& oOptions) const override + virtual void fillOptions(const char* iBegin, const char* iEnd, std::vector, std::string> >& oOptions) const override { oOptions.clear(); m_list.clear(); @@ -105,14 +105,14 @@ class FWGeoMaterialValidator : public FWValidatorBase unsigned int part_size = part.size(); std::string h = ""; // int cnt = 0; - oOptions.push_back(std::make_pair(boost::shared_ptr(new std::string(*m_list.begin())), h)); + oOptions.push_back(std::make_pair(std::make_shared(*m_list.begin()), h)); std::vector::iterator startIt = m_list.begin(); startIt++; for (std::vector::iterator i = startIt; i!=m_list.end(); ++i) { // std::cout << *i << " " << cnt++ << std::endl; if ((strlen(*i) >= part_size) && strncmp(*i, part.c_str(), part_size ) == 0) { - oOptions.push_back(std::make_pair(boost::shared_ptr(new std::string((*i))),&((*i)[part_size]) )); + oOptions.push_back(std::make_pair(std::make_shared((*i)),&((*i)[part_size]) )); } } } @@ -183,7 +183,7 @@ FWGeometryTableView::FWGeometryTableView(TEveWindowSlot* iParent, FWColorManager m_filterType.addEntry(kFilterShapeName, "ShapeName"); m_filterType.addEntry(kFilterShapeClassName, "ShapeClassName"); - boost::shared_ptr ptr( FWParameterSetterBase::makeSetterFor((FWParameterBase*)&m_filterType) ); + std::shared_ptr ptr( FWParameterSetterBase::makeSetterFor((FWParameterBase*)&m_filterType) ); ptr->attach((FWParameterBase*)&m_filterType, this); TGFrame* pframe = ptr->build(hp, false); diff --git a/Fireworks/Core/src/FWGeometryTableView.h b/Fireworks/Core/src/FWGeometryTableView.h index 52a1b2629515f..43065a320c7a7 100644 --- a/Fireworks/Core/src/FWGeometryTableView.h +++ b/Fireworks/Core/src/FWGeometryTableView.h @@ -88,7 +88,7 @@ class FWGeometryTableView : public FWGeometryTableViewBase FWEnumParameter m_proximityAlgo; - boost::shared_ptr m_filterTypeSetter; + std::shared_ptr m_filterTypeSetter; #endif diff --git a/Fireworks/Core/src/FWGeometryTableViewManager.cc b/Fireworks/Core/src/FWGeometryTableViewManager.cc index 1bdb319c9c1ca..d1186a6092f79 100644 --- a/Fireworks/Core/src/FWGeometryTableViewManager.cc +++ b/Fireworks/Core/src/FWGeometryTableViewManager.cc @@ -49,7 +49,7 @@ FWViewBase* FWGeometryTableViewManager::buildView(TEveWindowSlot* iParent, const std::string& type) { if (!s_geoManager) setGeoManagerFromFile(); - boost::shared_ptr view; + std::shared_ptr view; FWViewType::EType typeId = (type == FWViewType::sName[FWViewType::kGeometryTable]) ? FWViewType::kGeometryTable : FWViewType::kOverlapTable; if (typeId == FWViewType::kGeometryTable) @@ -58,7 +58,7 @@ FWGeometryTableViewManager::buildView(TEveWindowSlot* iParent, const std::string view.reset( new FWOverlapTableView(iParent, &colorManager())); view->setBackgroundColor(); - m_views.push_back(boost::shared_ptr (view)); + m_views.push_back(std::shared_ptr (view)); view->beingDestroyed_.connect(boost::bind(&FWGeometryTableViewManager::beingDestroyed, this,_1)); return view.get(); @@ -68,7 +68,7 @@ FWGeometryTableViewManager::buildView(TEveWindowSlot* iParent, const std::string void FWGeometryTableViewManager::beingDestroyed(const FWViewBase* iView) { - for(std::vector >::iterator it=m_views.begin(); it != m_views.end(); ++it) { + for(std::vector >::iterator it=m_views.begin(); it != m_views.end(); ++it) { if(it->get() == iView) { m_views.erase(it); return; @@ -79,7 +79,7 @@ FWGeometryTableViewManager::beingDestroyed(const FWViewBase* iView) void FWGeometryTableViewManager::colorsChanged() { - for(std::vector >::iterator it=m_views.begin(); it != m_views.end(); ++it) + for(std::vector >::iterator it=m_views.begin(); it != m_views.end(); ++it) (*it)->setBackgroundColor(); } diff --git a/Fireworks/Core/src/FWHLTValidator.cc b/Fireworks/Core/src/FWHLTValidator.cc index 10bf2bd371abc..dfb41cb1c0007 100644 --- a/Fireworks/Core/src/FWHLTValidator.cc +++ b/Fireworks/Core/src/FWHLTValidator.cc @@ -22,7 +22,7 @@ void FWHLTValidator::fillOptions(const char* iBegin, const char* iEnd, - std::vector, std::string> >& oOptions) const + std::vector, std::string> >& oOptions) const { oOptions.clear(); std::string part(iBegin,iEnd); @@ -51,7 +51,7 @@ FWHLTValidator::fillOptions(const char* iBegin, const char* iEnd, for(std::vector::const_iterator trigger = m_triggerNames.begin(); trigger != m_triggerNames.end(); ++trigger) if(part == trigger->substr(0,part_size) ) { - oOptions.push_back(std::make_pair(boost::shared_ptr(new std::string(*trigger)), + oOptions.push_back(std::make_pair(std::make_shared(*trigger), trigger->substr(part_size,trigger->size()-part_size))); } } diff --git a/Fireworks/Core/src/FWItemAccessorFactory.cc b/Fireworks/Core/src/FWItemAccessorFactory.cc index f35dc64e4d816..6144ef9297ec0 100644 --- a/Fireworks/Core/src/FWItemAccessorFactory.cc +++ b/Fireworks/Core/src/FWItemAccessorFactory.cc @@ -90,7 +90,7 @@ FWItemAccessorFactory::~FWItemAccessorFactory() mean that the product associated to @a iClass will not show up in the "Add Collection" table. */ -boost::shared_ptr +std::shared_ptr FWItemAccessorFactory::accessorFor(const TClass* iClass) const { static const bool debug = false; @@ -103,9 +103,8 @@ FWItemAccessorFactory::accessorFor(const TClass* iClass) const if (debug) fwLog(fwlog::kDebug) << "class " << iClass->GetName() << " uses FWItemTVirtualCollectionProxyAccessor." << std::endl; - return boost::shared_ptr( - new FWItemTVirtualCollectionProxyAccessor(iClass, - boost::shared_ptr(iClass->GetCollectionProxy()->Generate()))); + return std::make_shared(iClass, + std::shared_ptr(iClass->GetCollectionProxy()->Generate())); } // Iterate on the available plugins and use the one which handles @@ -121,7 +120,7 @@ FWItemAccessorFactory::accessorFor(const TClass* iClass) const if (debug) fwLog(fwlog::kDebug) << "class " << iClass->GetName() << " uses " << accessorName << "." << std::endl; - return boost::shared_ptr(FWItemAccessorRegistry::get()->create(accessorName, iClass)); + return std::shared_ptr(FWItemAccessorRegistry::get()->create(accessorName, iClass)); } if (hasMemberTVirtualCollectionProxy(iClass, member,offset)) @@ -132,13 +131,12 @@ FWItemAccessorFactory::accessorFor(const TClass* iClass) const << " which uses FWItemTVirtualCollectionProxyAccessor." << std::endl; - return boost::shared_ptr( - new FWItemTVirtualCollectionProxyAccessor(iClass, - boost::shared_ptr(member->GetCollectionProxy()->Generate()), - offset)); + return std::make_shared(iClass, + std::shared_ptr(member->GetCollectionProxy()->Generate()), + offset); } - return boost::shared_ptr(new FWItemSingleAccessor(iClass)); + return std::make_shared(iClass); } /** Helper method which @return true if the passes @a iClass can be accessed via diff --git a/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.cc b/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.cc index 90ffb9a3b0dd7..71d1bef7e46f0 100644 --- a/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.cc +++ b/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.cc @@ -33,7 +33,7 @@ // FWItemTVirtualCollectionProxyAccessor::FWItemTVirtualCollectionProxyAccessor( const TClass* iType, - boost::shared_ptr iProxy, + std::shared_ptr iProxy, size_t iOffset) : m_type(iType), m_colProxy(iProxy), diff --git a/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.h b/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.h index aec2bba4643e0..70fb219f19c29 100644 --- a/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.h +++ b/Fireworks/Core/src/FWItemTVirtualCollectionProxyAccessor.h @@ -19,7 +19,7 @@ // // system include files -#include "boost/shared_ptr.hpp" +#include // user include files #include "Fireworks/Core/interface/FWItemAccessorBase.h" @@ -31,7 +31,7 @@ class FWItemTVirtualCollectionProxyAccessor : public FWItemAccessorBase { public: FWItemTVirtualCollectionProxyAccessor(const TClass* iType, - boost::shared_ptr iProxy, + std::shared_ptr iProxy, size_t iOffset=0); virtual ~FWItemTVirtualCollectionProxyAccessor(); @@ -57,7 +57,7 @@ class FWItemTVirtualCollectionProxyAccessor : public FWItemAccessorBase { // ---------- member data -------------------------------- const TClass* m_type; - boost::shared_ptr m_colProxy; //should be something other than shared_ptr + std::shared_ptr m_colProxy; //should be something other than shared_ptr mutable const void * m_data; size_t m_offset; }; diff --git a/Fireworks/Core/src/FWModelChangeManager.cc b/Fireworks/Core/src/FWModelChangeManager.cc index 84cedbf2aa678..a2a2d4692bb3a 100644 --- a/Fireworks/Core/src/FWModelChangeManager.cc +++ b/Fireworks/Core/src/FWModelChangeManager.cc @@ -12,7 +12,7 @@ // system include files #include -#include +#include #include // user include files @@ -108,7 +108,7 @@ FWModelChangeManager::endChanges() itChanges != m_itemChanges.end(); ++itChanges,++index) { if( !guard ) { - // boost::shared_ptr done(this, &sendChangeSignalsAreDone); + // std::shared_ptr done(this, &sendChangeSignalsAreDone); guard = true; changeSignalsAreComing_(); } @@ -141,7 +141,7 @@ FWModelChangeManager::endChanges() { if (!guard) { - // boost::shared_ptr done(this, &sendChangeSignalsAreDone); + // std::shared_ptr done(this, &sendChangeSignalsAreDone); guard = true; changeSignalsAreComing_(); } diff --git a/Fireworks/Core/src/FWParameterSetterBase.cc b/Fireworks/Core/src/FWParameterSetterBase.cc index 43afa4d478c04..b46e2d26ba3d1 100644 --- a/Fireworks/Core/src/FWParameterSetterBase.cc +++ b/Fireworks/Core/src/FWParameterSetterBase.cc @@ -90,7 +90,7 @@ FWParameterSetterBase::update() const // static member functions // -boost::shared_ptr +std::shared_ptr FWParameterSetterBase::makeSetterFor(FWParameterBase* iParam) { static std::map s_paramToSetterMap; @@ -145,7 +145,7 @@ FWParameterSetterBase::makeSetterFor(FWParameterBase* iParam) //make it into the base class FWParameterSetterBase* p = static_cast(setterObj.address()); //Make a shared pointer to the base class that uses a destructor for the derived class, in order to match the above construct call. - boost::shared_ptr ptr(p, boost::bind(&edm::TypeWithDict::destruct,itFind->second,setterObj.address(),true)); + std::shared_ptr ptr(p, boost::bind(&edm::TypeWithDict::destruct,itFind->second,setterObj.address(),true)); return ptr; } diff --git a/Fireworks/Core/src/FWProxyBuilderConfiguration.cc b/Fireworks/Core/src/FWProxyBuilderConfiguration.cc index 58feca44fce40..e3d98f151944b 100644 --- a/Fireworks/Core/src/FWProxyBuilderConfiguration.cc +++ b/Fireworks/Core/src/FWProxyBuilderConfiguration.cc @@ -72,7 +72,7 @@ FWProxyBuilderConfiguration::makeSetter(TGCompositeFrame* frame, FWParameterBase { // std::cout << "make setter " << pb->name() << std::endl; - boost::shared_ptr ptr( FWParameterSetterBase::makeSetterFor(pb) ); + std::shared_ptr ptr( FWParameterSetterBase::makeSetterFor(pb) ); ptr->attach(pb, this); TGFrame* tmpFrame = ptr->build(frame, false); frame->AddFrame(tmpFrame, new TGLayoutHints(kLHintsExpandX)); diff --git a/Fireworks/Core/src/FWRPZView.cc b/Fireworks/Core/src/FWRPZView.cc index b048f465db4e5..aff659518c47e 100644 --- a/Fireworks/Core/src/FWRPZView.cc +++ b/Fireworks/Core/src/FWRPZView.cc @@ -13,7 +13,7 @@ // system include files #include #include -#include +#include #include "TGLViewer.h" #include "TGLScenePad.h" @@ -300,7 +300,7 @@ FWRPZView::importElements(TEveElement* iChildren, float iLayer, TEveElement* iPr float oldLayer = m_projMgr->GetCurrentDepth(); m_projMgr->SetCurrentDepth(iLayer); //make sure current depth is reset even if an exception is thrown - boost::shared_ptr sentry(m_projMgr, + std::shared_ptr sentry(m_projMgr, boost::bind(&TEveProjectionManager::SetCurrentDepth, _1,oldLayer)); m_projMgr->ImportElements(iChildren,iProjectedParent); diff --git a/Fireworks/Core/src/FWSimpleRepresentationChecker.cc b/Fireworks/Core/src/FWSimpleRepresentationChecker.cc index 9b52e895a7a18..2848caf734343 100644 --- a/Fireworks/Core/src/FWSimpleRepresentationChecker.cc +++ b/Fireworks/Core/src/FWSimpleRepresentationChecker.cc @@ -111,7 +111,7 @@ FWSimpleRepresentationChecker::infoFor(const std::string& iTypeName) const if(0==clss || 0==clss->GetTypeInfo()) { return FWRepresentationInfo(); } - boost::shared_ptr accessor = factory.accessorFor(clss); + std::shared_ptr accessor = factory.accessorFor(clss); const TClass* modelClass = accessor->modelType(); //std::cout <<" "<GetName()<<" "<< bool(modelClass == clss)<< std::endl; diff --git a/Fireworks/Core/src/FWTableView.cc b/Fireworks/Core/src/FWTableView.cc index 1a98cc9b35eb7..8d257609eaa1f 100644 --- a/Fireworks/Core/src/FWTableView.cc +++ b/Fireworks/Core/src/FWTableView.cc @@ -13,7 +13,7 @@ // system include files #include #include -#include +#include #include #include #include diff --git a/Fireworks/Core/src/FWTableViewManager.cc b/Fireworks/Core/src/FWTableViewManager.cc index 761ab7092a450..d6a820a89d5d9 100644 --- a/Fireworks/Core/src/FWTableViewManager.cc +++ b/Fireworks/Core/src/FWTableViewManager.cc @@ -368,7 +368,7 @@ class FWViewBase* FWTableViewManager::buildView(TEveWindowSlot* iParent, const std::string& /*type*/) { TEveManager::TRedrawDisabler disableRedraw(gEve); - boost::shared_ptr view(new FWTableView(iParent, this)); + auto view = std::make_shared(iParent, this); view->setBackgroundColor(colorManager().background()); m_views.push_back(view); view->beingDestroyed_.connect(boost::bind(&FWTableViewManager::beingDestroyed, diff --git a/Fireworks/Core/src/FWTriggerTableViewManager.cc b/Fireworks/Core/src/FWTriggerTableViewManager.cc index 4c50d256ae207..281f3b4d9f6d7 100644 --- a/Fireworks/Core/src/FWTriggerTableViewManager.cc +++ b/Fireworks/Core/src/FWTriggerTableViewManager.cc @@ -44,7 +44,7 @@ FWTriggerTableViewManager::~FWTriggerTableViewManager() class FWViewBase* FWTriggerTableViewManager::buildView(TEveWindowSlot* iParent, const std::string& type) { - boost::shared_ptr view; + std::shared_ptr view; if (type == FWViewType::sName[FWViewType::kTableHLT]) view.reset( new FWHLTTriggerTableView(iParent)); @@ -54,7 +54,7 @@ FWTriggerTableViewManager::buildView(TEveWindowSlot* iParent, const std::string& view->setProcessList(&(context().metadataManager()->processNamesInJob())); view->setBackgroundColor(colorManager().background()); - m_views.push_back(boost::shared_ptr (view)); + m_views.push_back(std::shared_ptr (view)); view->beingDestroyed_.connect(boost::bind(&FWTriggerTableViewManager::beingDestroyed, this,_1)); return view.get(); @@ -63,7 +63,7 @@ FWTriggerTableViewManager::buildView(TEveWindowSlot* iParent, const std::string& void FWTriggerTableViewManager::beingDestroyed(const FWViewBase* iView) { - for(std::vector >::iterator it= + for(std::vector >::iterator it= m_views.begin(), itEnd = m_views.end(); it != itEnd; ++it) { @@ -77,7 +77,7 @@ FWTriggerTableViewManager::beingDestroyed(const FWViewBase* iView) void FWTriggerTableViewManager::colorsChanged() { - for(std::vector >::iterator it= + for(std::vector >::iterator it= m_views.begin(), itEnd = m_views.end(); it != itEnd; ++it) { @@ -88,7 +88,7 @@ FWTriggerTableViewManager::colorsChanged() void FWTriggerTableViewManager::eventEnd() { - for(std::vector >::iterator it= + for(std::vector >::iterator it= m_views.begin(), itEnd = m_views.end(); it != itEnd; ++it) { @@ -100,7 +100,7 @@ void FWTriggerTableViewManager::updateProcessList() { // printf("FWTriggerTableViewManager::updateProcessLi\n"); - for(std::vector >::iterator it= + for(std::vector >::iterator it= m_views.begin(), itEnd = m_views.end(); it != itEnd; ++it) { diff --git a/Fireworks/Core/src/FWTypeToRepresentations.cc b/Fireworks/Core/src/FWTypeToRepresentations.cc index bc1f193438bc2..b043c15a4aa0a 100644 --- a/Fireworks/Core/src/FWTypeToRepresentations.cc +++ b/Fireworks/Core/src/FWTypeToRepresentations.cc @@ -58,7 +58,7 @@ FWTypeToRepresentations::~FWTypeToRepresentations() // member functions // void -FWTypeToRepresentations::add( boost::shared_ptr iChecker) +FWTypeToRepresentations::add( std::shared_ptr iChecker) { m_checkers.push_back(iChecker); if(m_typeToReps.size()) { @@ -78,7 +78,7 @@ void FWTypeToRepresentations::insert( const FWTypeToRepresentations& iOther) { m_typeToReps.clear(); - for(std::vector >::const_iterator it =iOther.m_checkers.begin(), + for(std::vector >::const_iterator it =iOther.m_checkers.begin(), itEnd = iOther.m_checkers.end(); it != itEnd; ++it) { @@ -96,7 +96,7 @@ FWTypeToRepresentations::representationsForType(const std::string& iTypeName) co if(itFound == m_typeToReps.end()) { std::vector reps; //check all reps - for(std::vector >::const_iterator it = m_checkers.begin(), + for(std::vector >::const_iterator it = m_checkers.begin(), itEnd = m_checkers.end(); it != itEnd; ++it) { diff --git a/Fireworks/Core/src/FWValidatorBase.h b/Fireworks/Core/src/FWValidatorBase.h index 0cb84be237eac..505f9be497f3b 100644 --- a/Fireworks/Core/src/FWValidatorBase.h +++ b/Fireworks/Core/src/FWValidatorBase.h @@ -21,7 +21,7 @@ // system include files #include #include -#include +#include // user include files @@ -40,7 +40,7 @@ class FWValidatorBase { // first: the full details about the substitution // second: exactly what should be inserted into the expression to complete the option virtual void fillOptions(const char* iBegin, const char* iEnd, - std::vector, std::string> >& oOptions) const = 0; + std::vector, std::string> >& oOptions) const = 0; // ---------- static member functions -------------------- diff --git a/Fireworks/Core/src/FWViewEnergyScaleEditor.cc b/Fireworks/Core/src/FWViewEnergyScaleEditor.cc index 3f37aa2c98f84..7c2bc4cf8e8cf 100644 --- a/Fireworks/Core/src/FWViewEnergyScaleEditor.cc +++ b/Fireworks/Core/src/FWViewEnergyScaleEditor.cc @@ -57,7 +57,7 @@ void FWViewEnergyScaleEditor::setEnabled(bool x) { m_enabled =x; - typedef std::vector > sList; + typedef std::vector > sList; for (sList::iterator i = m_setters.begin(); i!=m_setters.end(); ++i) { (*i)->setEnabled(m_enabled); @@ -75,7 +75,7 @@ FWViewEnergyScaleEditor::addParam(FWParameterBase* param, const char* title) leftPad *= 2; } - boost::shared_ptr ptr( FWParameterSetterBase::makeSetterFor(param) ); + std::shared_ptr ptr( FWParameterSetterBase::makeSetterFor(param) ); ptr->attach((FWParameterBase*)param, this); TGFrame* pframe = ptr->build(this); AddFrame(pframe, new TGLayoutHints(kLHintsLeft, leftPad, 0, 0, 0)); diff --git a/Fireworks/Core/src/FWViewManagerManager.cc b/Fireworks/Core/src/FWViewManagerManager.cc index 1bd854a722f61..cacbb3dd43e85 100644 --- a/Fireworks/Core/src/FWViewManagerManager.cc +++ b/Fireworks/Core/src/FWViewManagerManager.cc @@ -64,7 +64,7 @@ FWViewManagerManager::~FWViewManagerManager() // member functions // void -FWViewManagerManager::add( boost::shared_ptr iManager) +FWViewManagerManager::add( std::shared_ptr iManager) { m_viewManagers.push_back(iManager); iManager->setChangeManager(m_changeManager); @@ -88,7 +88,7 @@ FWViewManagerManager::registerEventItem(const FWEventItem*iItem) iItem->goingToBeDestroyed_.connect(boost::bind(&FWViewManagerManager::removeEventItem,this,_1)); //std::map >::iterator itFind = m_typeToBuilders.find(iItem->name()); - for(std::vector >::iterator itVM = m_viewManagers.begin(); + for(std::vector >::iterator itVM = m_viewManagers.begin(); itVM != m_viewManagers.end(); ++itVM) { (*itVM)->newItem(iItem); @@ -111,7 +111,7 @@ FWTypeToRepresentations FWViewManagerManager::supportedTypesAndRepresentations() const { FWTypeToRepresentations returnValue; - for(std::vector >::const_iterator itVM = m_viewManagers.begin(); + for(std::vector >::const_iterator itVM = m_viewManagers.begin(); itVM != m_viewManagers.end(); ++itVM) { FWTypeToRepresentations v = (*itVM)->supportedTypesAndRepresentations(); diff --git a/Fireworks/Core/test/unittest_changemanager.cc b/Fireworks/Core/test/unittest_changemanager.cc index b08248641d3a1..27814eb2b3a53 100644 --- a/Fireworks/Core/test/unittest_changemanager.cc +++ b/Fireworks/Core/test/unittest_changemanager.cc @@ -89,7 +89,7 @@ BOOST_AUTO_TEST_CASE( changemanager ) fireworks::Context context(&cm,0,0,0,0); - boost::shared_ptr accessor( new TestAccessor(&fVector)); + auto accessor = std::make_shared(&fVector); FWPhysicsObjectDesc pObj("Tracks",cls,"Tracks"); FWEventItem item(&context, 0,accessor,pObj); diff --git a/Fireworks/Core/test/unittest_modelexpressionselector.cc b/Fireworks/Core/test/unittest_modelexpressionselector.cc index e855d84aa9b67..799955784a1bd 100644 --- a/Fireworks/Core/test/unittest_modelexpressionselector.cc +++ b/Fireworks/Core/test/unittest_modelexpressionselector.cc @@ -74,7 +74,7 @@ BOOST_AUTO_TEST_CASE( modelexpressionselector ) fireworks::Context context(&cm,&sm,0,0,0); - boost::shared_ptr accessor( new TestAccessor(&fVector)); + auto accessor = std::make_shared(&fVector); FWPhysicsObjectDesc pObj("Tracks",cls,"Tracks"); FWEventItem item(&context, 0,accessor,pObj); diff --git a/Fireworks/Core/test/unittest_modelfilter.cc b/Fireworks/Core/test/unittest_modelfilter.cc index f1e0b127c78b4..3123647263ad8 100644 --- a/Fireworks/Core/test/unittest_modelfilter.cc +++ b/Fireworks/Core/test/unittest_modelfilter.cc @@ -69,7 +69,7 @@ BOOST_AUTO_TEST_CASE( itemfilter ) fireworks::Context context(&cm,&sm,0,0,0); - boost::shared_ptr accessor( new TestAccessor(&fVector)); + auto accessor = std::make_shared(&fVector); FWPhysicsObjectDesc pObj("Tracks",cls,"Tracks"); FWEventItem item(&context, 0,accessor,pObj); diff --git a/Fireworks/Core/test/unittest_selectionmanager.cc b/Fireworks/Core/test/unittest_selectionmanager.cc index 7560f26d9f9d7..8e8ccf3da215c 100644 --- a/Fireworks/Core/test/unittest_selectionmanager.cc +++ b/Fireworks/Core/test/unittest_selectionmanager.cc @@ -95,7 +95,7 @@ BOOST_AUTO_TEST_CASE( selectionmanager ) fireworks::Context context(&cm,&sm,0,0,0); - boost::shared_ptr accessor( new TestAccessor(&fVector)); + auto accessor = std::make_shared(&fVector); FWPhysicsObjectDesc pObj("Tracks",cls,"Tracks"); FWEventItem item(&context, 0,accessor,pObj);