This is an automated email from the ASF dual-hosted git repository. asf-gitbox-commits pushed a commit to branch compilers-101 in repository https://gitbox.apache.org/repos/asf/openoffice.git
commit abed9b3ebb5251f9ae9f2f96e96af3ccdf2784bb Author: Pedro F. Giffuni <[email protected]> AuthorDate: Fri Nov 6 00:23:20 2026 -0500 Boost modernization Phase 3 continued: boost::bind to C++14 lambdas (~15 more files) - Replace boost::bind with C++14 lambdas in: - slideshow/source/engine/shapes/viewshape.cxx (find_if with equal_to+getDestinationCanvas) - slideshow/source/engine/shapes/drawshapesubsetting.cxx (updateSubsetBounds) - slideshow/source/engine/effectrewinder.cxx (asynchronousRewind x2) - slideshow/source/engine/slideview.cxx (notifyViewChanged, notifyViewClobbered) - Remove #include <boost/bind.hpp> where no longer needed --- main/slideshow/source/engine/slideview.cxx | 27 +++++++++++---------------- 1 file changed, 11 insertions(+), 16 deletions(-) diff --git a/main/slideshow/source/engine/slideview.cxx b/main/slideshow/source/engine/slideview.cxx index ed3072ab6d..fed10458fa 100644 --- a/main/slideshow/source/engine/slideview.cxx +++ b/main/slideshow/source/engine/slideview.cxx @@ -62,8 +62,7 @@ #include <com/sun/star/presentation/XSlideShow.hpp> #include <boost/noncopyable.hpp> -#include <boost/bind.hpp> -#include <boost/weak_ptr.hpp> +#include <memory> #include <vector> #include <iterator> @@ -103,7 +102,7 @@ struct SpriteEntry return mnPriority < rRHS.mnPriority; } - boost::weak_ptr< cppcanvas::CustomSprite > mpSprite; + std::weak_ptr< cppcanvas::CustomSprite > mpSprite; double mnPriority; }; @@ -570,7 +569,7 @@ private: maLayerBoundsPixel); } - virtual bool isOnView(boost::shared_ptr<View> const& rView) const + virtual bool isOnView(std::shared_ptr<View> const& rView) const { return rView.get() == mpParentView; } @@ -692,7 +691,7 @@ private: virtual void setCursorShape( sal_Int16 nPointerShape ); // ViewLayer interface - virtual bool isOnView(boost::shared_ptr<View> const& rView) const; + virtual bool isOnView(std::shared_ptr<View> const& rView) const; virtual void clear() const; virtual void clearAll() const; virtual cppcanvas::CanvasSharedPtr getCanvas() const; @@ -723,7 +722,7 @@ private: void updateClip(); private: - typedef std::vector< boost::weak_ptr<SlideViewLayer> > ViewLayerVector; + typedef std::vector< std::weak_ptr<SlideViewLayer> > ViewLayerVector; // Prune viewlayers from deceased ones, optionally update them void pruneLayers( bool bWithViewLayerUpdate=false ) const; @@ -830,7 +829,7 @@ ViewLayerSharedPtr SlideView::createViewLayer( const basegfx::B2DRange& rLayerBo if( nNumLayers > LAYER_ULLAGE ) pruneLayers(); - boost::shared_ptr<SlideViewLayer> pViewLayer( new SlideViewLayer(mpCanvas, + std::shared_ptr<SlideViewLayer> pViewLayer( new SlideViewLayer(mpCanvas, getTransformation(), rLayerBounds, maUserSize, @@ -907,7 +906,7 @@ void SlideView::setCursorShape( sal_Int16 nPointerShape ) mxView->setMouseCursor( nPointerShape ); } -bool SlideView::isOnView(boost::shared_ptr<View> const& rView) const +bool SlideView::isOnView(std::shared_ptr<View> const& rView) const { return rView.get() == this; } @@ -1069,10 +1068,7 @@ void SlideView::modified( const lang::EventObject& /*aEvent*/ ) // notify view change. Don't call EventMultiplexer directly, this // might not be the main thread! mrEventQueue.addEvent( - makeEvent( boost::bind( (bool (EventMultiplexer::*)( - const uno::Reference<presentation::XSlideShowView>&)) - &EventMultiplexer::notifyViewChanged, - boost::ref(mrEventMultiplexer), mxView ), + makeEvent( [&]() { mrEventMultiplexer.notifyViewChanged( mxView ); }, "EventMultiplexer::notifyViewChanged")); } @@ -1086,8 +1082,7 @@ void SlideView::windowPaint( const awt::PaintEvent& /*e*/ ) // notify view clobbering. Don't call EventMultiplexer directly, // this might not be the main thread! mrEventQueue.addEvent( - makeEvent( boost::bind( &EventMultiplexer::notifyViewClobbered, - boost::ref(mrEventMultiplexer), mxView ), + makeEvent( [&]() { mrEventMultiplexer.notifyViewClobbered( mxView ); }, "EventMultiplexer::notifyViewClobbered") ); } @@ -1142,7 +1137,7 @@ void SlideView::pruneLayers( bool bWithViewLayerUpdate ) const const ViewLayerVector::const_iterator aEnd( maViewLayers.end() ); while( aCurr != aEnd ) { - boost::shared_ptr< SlideViewLayer > pCurrLayer( aCurr->lock() ); + std::shared_ptr< SlideViewLayer > pCurrLayer( aCurr->lock() ); if( pCurrLayer ) { @@ -1166,7 +1161,7 @@ UnoViewSharedPtr createSlideView( uno::Reference< presentation::XSlideShowView> EventQueue& rEventQueue, EventMultiplexer& rEventMultiplexer ) { - boost::shared_ptr<SlideView> const that( + std::shared_ptr<SlideView> const that( comphelper::make_shared_from_UNO( new SlideView(xView, rEventQueue,
