diff options
Diffstat (limited to 'slideshow/source/engine/shapes/drawshape.cxx')
-rw-r--r-- | slideshow/source/engine/shapes/drawshape.cxx | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/slideshow/source/engine/shapes/drawshape.cxx b/slideshow/source/engine/shapes/drawshape.cxx index 7c77a3c15f2b..875dffebb58c 100644 --- a/slideshow/source/engine/shapes/drawshape.cxx +++ b/slideshow/source/engine/shapes/drawshape.cxx @@ -632,16 +632,14 @@ namespace slideshow void DrawShape::addViewLayer( const ViewLayerSharedPtr& rNewLayer, bool bRedrawLayer ) { - ViewShapeVector::iterator aEnd( maViewShapes.end() ); - // already added? - if( ::std::find_if( maViewShapes.begin(), - aEnd, - ::boost::bind<bool>( + if( ::std::any_of( maViewShapes.begin(), + maViewShapes.end(), + ::boost::bind<bool>( ::std::equal_to< ViewLayerSharedPtr >(), ::boost::bind( &ViewShape::getViewLayer, _1 ), - ::boost::cref( rNewLayer ) ) ) != aEnd ) + ::boost::cref( rNewLayer ) ) )) { // yes, nothing to do return; |