oox: replace boost::bind with C++11 lambda
Change-Id: I8b3c029db18f62cc41e5fc12582e10bf2a67d2c7
This commit is contained in:
@@ -42,7 +42,6 @@
|
||||
#include <unordered_map>
|
||||
#include <vector>
|
||||
#include <boost/algorithm/string.hpp>
|
||||
#include <boost/bind.hpp>
|
||||
#include <boost/intrusive_ptr.hpp>
|
||||
#include <boost/next_prior.hpp>
|
||||
#include <boost/noncopyable.hpp>
|
||||
|
@@ -18,7 +18,6 @@
|
||||
*/
|
||||
|
||||
#include <functional>
|
||||
#include <boost/bind.hpp>
|
||||
|
||||
#include <com/sun/star/awt/Point.hpp>
|
||||
#include <com/sun/star/awt/Size.hpp>
|
||||
@@ -76,10 +75,10 @@ void DiagramData::dump()
|
||||
{
|
||||
OSL_TRACE("Dgm: DiagramData # of cnx: %zu", maConnections.size() );
|
||||
std::for_each( maConnections.begin(), maConnections.end(),
|
||||
boost::bind( &dgm::Connection::dump, _1 ) );
|
||||
[] (dgm::Connection & rConnection) { rConnection.dump(); } );
|
||||
OSL_TRACE("Dgm: DiagramData # of pt: %zu", maPoints.size() );
|
||||
std::for_each( maPoints.begin(), maPoints.end(),
|
||||
boost::bind( &dgm::Point::dump, _1 ) );
|
||||
[] (dgm::Point & rPoint) { rPoint.dump(); } );
|
||||
}
|
||||
|
||||
void Diagram::setData( const DiagramDataPtr & pData)
|
||||
|
@@ -20,7 +20,6 @@
|
||||
#include "diagramlayoutatoms.hxx"
|
||||
|
||||
#include <functional>
|
||||
#include <boost/bind.hpp>
|
||||
|
||||
#include <osl/diagnose.h>
|
||||
#include <basegfx/numeric/ftools.hxx>
|
||||
@@ -86,7 +85,7 @@ void LayoutAtom::dump(int level)
|
||||
typeid(*this).name() );
|
||||
const std::vector<LayoutAtomPtr>& pChildren=getChildren();
|
||||
std::for_each( pChildren.begin(), pChildren.end(),
|
||||
boost::bind( &LayoutAtom::dump, _1, level + 1 ) );
|
||||
[level] (LayoutAtomPtr const& pAtom) { pAtom->dump(level + 1); } );
|
||||
}
|
||||
|
||||
ForEachAtom::ForEachAtom(const Reference< XFastAttributeList >& xAttributes)
|
||||
@@ -584,9 +583,7 @@ void ShapeCreationVisitor::defaultVisit(LayoutAtom& rAtom)
|
||||
{
|
||||
const std::vector<LayoutAtomPtr>& pChildren=rAtom.getChildren();
|
||||
std::for_each( pChildren.begin(), pChildren.end(),
|
||||
boost::bind( &LayoutAtom::accept,
|
||||
_1,
|
||||
boost::ref(*this)) );
|
||||
[this] (LayoutAtomPtr const& pAtom) { pAtom->accept(*this); } );
|
||||
}
|
||||
|
||||
void ShapeCreationVisitor::visit(ConstraintAtom& /*rAtom*/)
|
||||
@@ -611,9 +608,7 @@ void ShapeCreationVisitor::visit(ForEachAtom& rAtom)
|
||||
// getPointsPresNameMap()
|
||||
ShallowPresNameVisitor aVisitor(mrDgm);
|
||||
std::for_each( pChildren.begin(), pChildren.end(),
|
||||
boost::bind( &LayoutAtom::accept,
|
||||
_1,
|
||||
boost::ref(aVisitor)) );
|
||||
[&] (LayoutAtomPtr const& pAtom) { pAtom->accept(aVisitor); } );
|
||||
nChildren = aVisitor.getCount();
|
||||
}
|
||||
|
||||
@@ -627,9 +622,7 @@ void ShapeCreationVisitor::visit(ForEachAtom& rAtom)
|
||||
{
|
||||
// TODO there is likely some conditions
|
||||
std::for_each( pChildren.begin(), pChildren.end(),
|
||||
boost::bind( &LayoutAtom::accept,
|
||||
_1,
|
||||
boost::ref(*this)) );
|
||||
[this] (LayoutAtomPtr const& pAtom) { pAtom->accept(*this); } );
|
||||
}
|
||||
|
||||
// and restore idx
|
||||
@@ -697,9 +690,7 @@ void ShapeLayoutingVisitor::defaultVisit(LayoutAtom& rAtom)
|
||||
// visit all children, one of them needs to be the layout algorithm
|
||||
const std::vector<LayoutAtomPtr>& pChildren=rAtom.getChildren();
|
||||
std::for_each( pChildren.begin(), pChildren.end(),
|
||||
boost::bind( &LayoutAtom::accept,
|
||||
_1,
|
||||
boost::ref(*this)) );
|
||||
[this] (LayoutAtomPtr const& pAtom) { pAtom->accept(*this); } );
|
||||
}
|
||||
|
||||
void ShapeLayoutingVisitor::visit(ConstraintAtom& /*rAtom*/)
|
||||
@@ -738,9 +729,7 @@ void ShallowPresNameVisitor::defaultVisit(LayoutAtom& rAtom)
|
||||
// name set
|
||||
const std::vector<LayoutAtomPtr>& pChildren=rAtom.getChildren();
|
||||
std::for_each( pChildren.begin(), pChildren.end(),
|
||||
boost::bind( &LayoutAtom::accept,
|
||||
_1,
|
||||
boost::ref(*this)) );
|
||||
[this] (LayoutAtomPtr const& pAtom) { pAtom->accept(*this); } );
|
||||
}
|
||||
|
||||
void ShallowPresNameVisitor::visit(ConstraintAtom& /*rAtom*/)
|
||||
|
Reference in New Issue
Block a user