diff --git a/common/commit.cpp b/common/commit.cpp index c2b14de7f7..938f773ed1 100644 --- a/common/commit.cpp +++ b/common/commit.cpp @@ -25,7 +25,6 @@ #include #include -#include COMMIT::COMMIT() { @@ -37,7 +36,7 @@ COMMIT::~COMMIT() { if( !m_committed ) { - BOOST_FOREACH( COMMIT_LINE& ent, m_changes ) + for( COMMIT_LINE& ent : m_changes ) { if( ent.m_copy ) delete ent.m_copy; @@ -89,6 +88,17 @@ COMMIT& COMMIT::Stage( EDA_ITEM* aItem, CHANGE_TYPE aChangeType ) } +COMMIT& COMMIT::Stage( std::vector& container, CHANGE_TYPE aChangeType ) +{ + for( EDA_ITEM* item : container ) + { + Stage( item, aChangeType ); + } + + return *this; +} + + void COMMIT::Stage( const PICKED_ITEMS_LIST& aItems, CHANGE_TYPE aChangeType ) { for( unsigned int i = 0; i < aItems.GetCount(); i++ ) diff --git a/common/commit.h b/common/commit.h index 4256c7f8a2..3e0b11557f 100644 --- a/common/commit.h +++ b/common/commit.h @@ -29,7 +29,6 @@ #include #include -#include class PICKED_ITEMS_LIST; @@ -77,13 +76,6 @@ public: ///> Adds a change of the item aItem of type aChangeType to the change list. virtual COMMIT& Stage( EDA_ITEM* aItem, CHANGE_TYPE aChangeType ); - void Stage( std::vector& container, CHANGE_TYPE aChangeType ) - { - BOOST_FOREACH( EDA_ITEM* item, container ) - { - Stage( item, aChangeType ); - } - } void Stage( const PICKED_ITEMS_LIST& aItems, CHANGE_TYPE aChangeType );