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 b0d3eea05c8b3a935af4fd1b9abe23233497af4c Author: Pedro Giffuni <[email protected]> AuthorDate: Sat Nov 7 11:37:36 2026 -0500 Boost modernization Phase 1: scoped_ptr, array, tuple to C++11 std equivalents --- main/basebmp/inc/basebmp/bitmapdevice.hxx | 12 ++--- main/basegfx/source/range/b2dpolyrange.cxx | 26 +++++------ main/canvas/inc/canvas/rendering/bitmap.hxx | 20 ++++----- .../source/directx/dx_canvashelper_texturefill.cxx | 7 +-- .../canvas/source/vcl/canvashelper_texturefill.cxx | 1 + .../oox/drawingml/diagram/diagramlayoutatoms.hxx | 14 +++--- main/oox/inc/oox/ppt/animationspersist.hxx | 8 ++-- .../ui/framework/factories/BasicPaneFactory.hxx | 8 ++-- .../ui/framework/factories/BasicViewFactory.hxx | 22 ++++----- .../ui/framework/module/ReadOnlyModeObserver.hxx | 6 +-- main/sd/source/ui/inc/SlideSorter.hxx | 52 +++++++++++----------- main/sd/source/ui/inc/ToolBarManager.hxx | 18 ++++---- main/sd/source/ui/inc/ViewShellBase.hxx | 18 ++++---- main/sd/source/ui/inc/ViewTabBar.hxx | 10 ++--- .../ui/inc/framework/ConfigurationController.hxx | 6 +-- .../sd/source/ui/inc/framework/FrameworkHelper.hxx | 18 ++++---- .../source/ui/inc/taskpane/ToolPanelViewShell.hxx | 8 ++-- .../source/ui/slidesorter/cache/SlsBitmapCache.hxx | 8 ++-- .../ui/slidesorter/cache/SlsGenericPageCache.hxx | 7 +-- .../inc/controller/SlideSorterController.hxx | 31 ++++++------- .../ui/slidesorter/inc/controller/SlsAnimator.hxx | 8 ++-- .../ui/slidesorter/inc/view/SlsButtonBar.hxx | 19 ++++---- .../slidesorter/inc/view/SlsPageObjectPainter.hxx | 19 ++++---- .../ui/slidesorter/shell/SlideSorterService.hxx | 8 ++-- .../ui/slidesorter/view/SlsLayeredDevice.hxx | 10 ++--- .../ui/slidesorter/view/SlsPageObjectPainter.cxx | 7 +-- main/sd/source/ui/view/DocumentRenderer.cxx | 35 ++++++++------- main/sdext/source/pdfimport/wrapper/wrapper.cxx | 4 +- main/sdext/source/presenter/PresenterAnimation.hxx | 10 ++--- .../presenter/PresenterPaneBorderPainter.hxx | 10 ++--- main/sfx2/source/sidebar/Panel.hxx | 7 ++- main/sfx2/source/sidebar/TabBar.hxx | 8 ++-- .../source/engine/shapes/shapeimporter.cxx | 6 +-- main/slideshow/source/inc/screenupdater.hxx | 7 +-- main/svx/source/sidebar/line/LinePropertyPanel.hxx | 51 ++++++++++----------- main/sw/inc/doc.hxx | 16 +++---- main/vcl/source/gdi/image.cxx | 4 +- main/xmloff/source/text/txtimp.cxx | 6 +-- 38 files changed, 272 insertions(+), 263 deletions(-) diff --git a/main/basebmp/inc/basebmp/bitmapdevice.hxx b/main/basebmp/inc/basebmp/bitmapdevice.hxx index d593b0d529..82128d0c58 100644 --- a/main/basebmp/inc/basebmp/bitmapdevice.hxx +++ b/main/basebmp/inc/basebmp/bitmapdevice.hxx @@ -27,8 +27,8 @@ #include <sal/types.h> #include <basebmp/drawmodes.hxx> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> #include <boost/shared_array.hpp> #include <boost/enable_shared_from_this.hpp> #include <boost/noncopyable.hpp> @@ -56,9 +56,9 @@ namespace basebmp // Temporary. Use like the tools color object class Color; -typedef boost::shared_ptr< class BitmapDevice > BitmapDeviceSharedPtr; +typedef std::shared_ptr< class BitmapDevice > BitmapDeviceSharedPtr; typedef boost::shared_array< sal_uInt8 > RawMemorySharedArray; -typedef boost::shared_ptr< const std::vector<Color> > PaletteMemorySharedVector; +typedef std::shared_ptr< const std::vector<Color> > PaletteMemorySharedVector; struct ImplBitmapDevice; @@ -74,7 +74,7 @@ struct ImplBitmapDevice; works best when given as an eight bit grey bitmap. Everything else is accepted, but potentially slow. */ -class BASEBMP_DLLPUBLIC BitmapDevice : public boost::enable_shared_from_this<BitmapDevice>, +class BASEBMP_DLLPUBLIC BitmapDevice : public std::enable_shared_from_this<BitmapDevice>, private boost::noncopyable { public: @@ -636,7 +636,7 @@ private: BitmapDeviceSharedPtr getGenericRenderer() const; - boost::scoped_ptr< ImplBitmapDevice > mpImpl; + std::unique_ptr< ImplBitmapDevice > mpImpl; }; /** Factory method to create a BitmapDevice for given scanline format diff --git a/main/basegfx/source/range/b2dpolyrange.cxx b/main/basegfx/source/range/b2dpolyrange.cxx index c5cb1a6cb2..4fcb8ccf2c 100644 --- a/main/basegfx/source/range/b2dpolyrange.cxx +++ b/main/basegfx/source/range/b2dpolyrange.cxx @@ -31,7 +31,7 @@ #include <basegfx/polygon/b2dpolypolygon.hxx> #include <boost/bind.hpp> -#include <boost/tuple/tuple.hpp> +#include <tuple> #include <algorithm> #include <vector> @@ -66,9 +66,9 @@ namespace basegfx {} explicit ImplB2DPolyRange( const B2DPolyRange::ElementType& rElem ) : - maBounds( boost::get<0>(rElem) ), - maRanges( 1, boost::get<0>(rElem) ), - maOrient( 1, boost::get<1>(rElem) ) + maBounds( std::get<0>(rElem) ), + maRanges( 1, std::get<0>(rElem) ), + maOrient( 1, std::get<1>(rElem) ) {} explicit ImplB2DPolyRange( const B2DRange& rRange, B2VectorOrientation eOrient ) : @@ -89,14 +89,14 @@ namespace basegfx B2DPolyRange::ElementType getElement(sal_uInt32 nIndex) const { - return boost::make_tuple(maRanges[nIndex], + return std::make_tuple(maRanges[nIndex], maOrient[nIndex]); } void setElement(sal_uInt32 nIndex, const B2DPolyRange::ElementType& rElement ) { - maRanges[nIndex] = boost::get<0>(rElement); - maOrient[nIndex] = boost::get<1>(rElement); + maRanges[nIndex] = std::get<0>(rElement); + maOrient[nIndex] = std::get<1>(rElement); updateBounds(); } @@ -109,9 +109,9 @@ namespace basegfx void insertElement(sal_uInt32 nIndex, const B2DPolyRange::ElementType& rElement, sal_uInt32 nCount) { - maRanges.insert(maRanges.begin()+nIndex, nCount, boost::get<0>(rElement)); - maOrient.insert(maOrient.begin()+nIndex, nCount, boost::get<1>(rElement)); - maBounds.expand(boost::get<0>(rElement)); + maRanges.insert(maRanges.begin()+nIndex, nCount, std::get<0>(rElement)); + maOrient.insert(maOrient.begin()+nIndex, nCount, std::get<1>(rElement)); + maBounds.expand(std::get<0>(rElement)); } void insertElement(sal_uInt32 nIndex, const B2DRange& rRange, B2VectorOrientation eOrient, sal_uInt32 nCount) @@ -123,9 +123,9 @@ namespace basegfx void appendElement(const B2DPolyRange::ElementType& rElement, sal_uInt32 nCount) { - maRanges.insert(maRanges.end(), nCount, boost::get<0>(rElement)); - maOrient.insert(maOrient.end(), nCount, boost::get<1>(rElement)); - maBounds.expand(boost::get<0>(rElement)); + maRanges.insert(maRanges.end(), nCount, std::get<0>(rElement)); + maOrient.insert(maOrient.end(), nCount, std::get<1>(rElement)); + maBounds.expand(std::get<0>(rElement)); } void appendElement(const B2DRange& rRange, B2VectorOrientation eOrient, sal_uInt32 nCount) diff --git a/main/canvas/inc/canvas/rendering/bitmap.hxx b/main/canvas/inc/canvas/rendering/bitmap.hxx index 0e9a0bed05..e211649eee 100644 --- a/main/canvas/inc/canvas/rendering/bitmap.hxx +++ b/main/canvas/inc/canvas/rendering/bitmap.hxx @@ -33,8 +33,8 @@ #include <canvas/rendering/icachedprimitive.hxx> #include <canvas/rendering/isurfaceproxymanager.hxx> -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> #include <vector> namespace basegfx @@ -218,7 +218,7 @@ namespace canvas const ::com::sun::star::rendering::RenderState& renderState, const ::com::sun::star::uno::Sequence< ::com::sun::star::rendering::Texture >& textures, - const ::std::vector< ::boost::shared_ptr<Bitmap> >& textureAnnotations, + const ::std::vector< ::std::shared_ptr<Bitmap> >& textureAnnotations, const ::com::sun::star::rendering::StrokeAttributes& strokeAttributes ); /** See XCanvas interface @@ -235,7 +235,7 @@ namespace canvas const ::com::sun::star::rendering::RenderState& renderState, const ::com::sun::star::uno::Sequence< ::com::sun::star::rendering::Texture >& textures, - const ::std::vector< ::boost::shared_ptr<Bitmap> >& textureAnnotations, + const ::std::vector< ::std::shared_ptr<Bitmap> >& textureAnnotations, const ::com::sun::star::uno::Reference< ::com::sun::star::geometry::XMapping2D >& xMapping, const ::com::sun::star::rendering::StrokeAttributes& strokeAttributes ); @@ -260,7 +260,7 @@ namespace canvas const ::com::sun::star::rendering::RenderState& renderState, const ::com::sun::star::uno::Sequence< ::com::sun::star::rendering::Texture >& textures, - const ::std::vector< ::boost::shared_ptr<Bitmap> >& textureAnnotations ); + const ::std::vector< ::std::shared_ptr<Bitmap> >& textureAnnotations ); /** See XCanvas interface @param textureAnnotations @@ -276,7 +276,7 @@ namespace canvas const ::com::sun::star::rendering::RenderState& renderState, const ::com::sun::star::uno::Sequence< ::com::sun::star::rendering::Texture >& textures, - const ::std::vector< ::boost::shared_ptr<Bitmap> >& textureAnnotations, + const ::std::vector< ::std::shared_ptr<Bitmap> >& textureAnnotations, const ::com::sun::star::uno::Reference< ::com::sun::star::geometry::XMapping2D >& xMapping ); @@ -288,7 +288,7 @@ namespace canvas const ::com::sun::star::rendering::RenderState& renderState ); /// See XCanvas interface ICachedPrimitiveSharedPtr drawBitmap( - const ::boost::shared_ptr<Bitmap>& rImage, + const ::std::shared_ptr<Bitmap>& rImage, const ::com::sun::star::rendering::ViewState& viewState, const ::com::sun::star::rendering::RenderState& renderState ); @@ -300,17 +300,17 @@ namespace canvas const ::com::sun::star::rendering::RenderState& renderState ); /// See XCanvas interface ICachedPrimitiveSharedPtr drawBitmapModulated( - const ::boost::shared_ptr<Bitmap>& rImage, + const ::std::shared_ptr<Bitmap>& rImage, const ::com::sun::star::rendering::ViewState& viewState, const ::com::sun::star::rendering::RenderState& renderState ); private: friend class ImplBitmap; - const ::boost::scoped_ptr< ImplBitmap > mpImpl; + const ::std::unique_ptr< ImplBitmap > mpImpl; }; - typedef ::boost::shared_ptr< Bitmap > BitmapSharedPtr; + typedef ::std::shared_ptr< Bitmap > BitmapSharedPtr; } #endif /* INCLUDED_CANVAS_BITMAP_HXX */ diff --git a/main/canvas/source/directx/dx_canvashelper_texturefill.cxx b/main/canvas/source/directx/dx_canvashelper_texturefill.cxx index 315745450b..33a8afca7a 100644 --- a/main/canvas/source/directx/dx_canvashelper_texturefill.cxx +++ b/main/canvas/source/directx/dx_canvashelper_texturefill.cxx @@ -23,6 +23,7 @@ // MARKER(update_precomp.py): autogen include statement, do not remove #include "precompiled_canvas.hxx" +#include <tuple> #include <canvas/debug.hxx> #include <tools/diagnose_ex.h> @@ -49,7 +50,7 @@ #include <boost/scoped_ptr.hpp> #include <boost/bind.hpp> -#include <boost/tuple/tuple.hpp> +#include <memory> using namespace ::com::sun::star; @@ -58,7 +59,7 @@ namespace dxcanvas { namespace { - typedef ::boost::shared_ptr< Gdiplus::PathGradientBrush > PathGradientBrushSharedPtr; + typedef ::std::shared_ptr< Gdiplus::PathGradientBrush > PathGradientBrushSharedPtr; bool fillLinearGradient( GraphicsSharedPtr& rGraphics, const ::canvas::ParametricPolyPolygon::Values& /*rValues*/, @@ -335,7 +336,7 @@ namespace dxcanvas std::ptrdiff_t nIndex; double fAlpha; const double fT( i/double(nStepCount) ); - boost::tuples::tie(nIndex,fAlpha)=aLerper.lerp(fT); + std::tie(nIndex,fAlpha)=aLerper.lerp(fT); const Gdiplus::Color aFillColor( static_cast<BYTE>( basegfx::tools::lerp(rColors[nIndex].GetRed(),rColors[nIndex+1].GetRed(),fAlpha) ), diff --git a/main/canvas/source/vcl/canvashelper_texturefill.cxx b/main/canvas/source/vcl/canvashelper_texturefill.cxx index 7b922a3280..f6e62d7c6b 100644 --- a/main/canvas/source/vcl/canvashelper_texturefill.cxx +++ b/main/canvas/source/vcl/canvashelper_texturefill.cxx @@ -59,6 +59,7 @@ #include <canvas/canvastools.hxx> #include <canvas/parametricpolypolygon.hxx> +#include <boost/bind.hpp> #include <boost/bind.hpp> #include <boost/tuple/tuple.hpp> diff --git a/main/oox/inc/oox/drawingml/diagram/diagramlayoutatoms.hxx b/main/oox/inc/oox/drawingml/diagram/diagramlayoutatoms.hxx index dea5561fda..7a6666b196 100644 --- a/main/oox/inc/oox/drawingml/diagram/diagramlayoutatoms.hxx +++ b/main/oox/inc/oox/drawingml/diagram/diagramlayoutatoms.hxx @@ -31,8 +31,8 @@ #include <map> #include <string> -#include <boost/shared_ptr.hpp> -#include <boost/array.hpp> +#include <memory> +#include <array> #include <com/sun/star/uno/Any.hxx> #include <com/sun/star/xml/sax/XFastAttributeList.hpp> @@ -78,7 +78,7 @@ private: class LayoutAtom; -typedef boost::shared_ptr< LayoutAtom > LayoutAtomPtr; +typedef std::shared_ptr< LayoutAtom > LayoutAtomPtr; /** abstract Atom for the layout */ class LayoutAtom @@ -129,7 +129,7 @@ private: IteratorAttr maIter; }; -typedef boost::shared_ptr< ForEachAtom > ForEachAtomPtr; +typedef std::shared_ptr< ForEachAtom > ForEachAtomPtr; class ConditionAtom @@ -155,7 +155,7 @@ private: ConditionAttr maCond; }; -typedef boost::shared_ptr< ConditionAtom > ConditionAtomPtr; +typedef std::shared_ptr< ConditionAtom > ConditionAtomPtr; /** "choose" statements. Atoms will be tested in order. */ @@ -185,7 +185,7 @@ public: }; // we know that the array is of fixed size // the use of Any allow having empty values - typedef boost::array< ::com::sun::star::uno::Any, 9 > VarMap; + typedef std::array< ::com::sun::star::uno::Any, 9 > VarMap; virtual ~LayoutNode() {} @@ -198,7 +198,7 @@ private: std::vector< ShapePtr > mpShapes; }; -typedef boost::shared_ptr< LayoutNode > LayoutNodePtr; +typedef std::shared_ptr< LayoutNode > LayoutNodePtr; } } diff --git a/main/oox/inc/oox/ppt/animationspersist.hxx b/main/oox/inc/oox/ppt/animationspersist.hxx index 31668fddb2..760196a173 100644 --- a/main/oox/inc/oox/ppt/animationspersist.hxx +++ b/main/oox/inc/oox/ppt/animationspersist.hxx @@ -26,8 +26,8 @@ #define OOX_PPT_ANIMATIONPERSIST #include <list> -#include <boost/shared_ptr.hpp> -#include <boost/array.hpp> +#include <memory> +#include <array> #include <rtl/ustring.hxx> @@ -52,7 +52,7 @@ namespace oox { namespace ppt { _NP_SIZE }; - typedef boost::array< ::com::sun::star::uno::Any, _NP_SIZE > NodePropertyMap; + typedef std::array< ::com::sun::star::uno::Any, _NP_SIZE > NodePropertyMap; /** data for CT_TLShapeTargetElement */ @@ -85,7 +85,7 @@ namespace oox { namespace ppt { ShapeTargetElement maShapeTarget; }; - typedef boost::shared_ptr< AnimTargetElement > AnimTargetElementPtr; + typedef std::shared_ptr< AnimTargetElement > AnimTargetElementPtr; struct AnimationCondition; diff --git a/main/sd/source/ui/framework/factories/BasicPaneFactory.hxx b/main/sd/source/ui/framework/factories/BasicPaneFactory.hxx index 00f6040fe3..1a16760fe0 100644 --- a/main/sd/source/ui/framework/factories/BasicPaneFactory.hxx +++ b/main/sd/source/ui/framework/factories/BasicPaneFactory.hxx @@ -38,8 +38,8 @@ #include "UpdateLockManager.hxx" -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> namespace css = ::com::sun::star; @@ -118,9 +118,9 @@ private: ViewShellBase* mpViewShellBase; class PaneDescriptor; class PaneContainer; - ::boost::scoped_ptr<PaneContainer> mpPaneContainer; + ::std::unique_ptr<PaneContainer> mpPaneContainer; bool mbFirstUpdateSeen; - ::boost::shared_ptr<UpdateLockManager> mpUpdateLockManager; + ::std::shared_ptr<UpdateLockManager> mpUpdateLockManager; /** Create a new instance of FrameWindowPane. @param rPaneId diff --git a/main/sd/source/ui/framework/factories/BasicViewFactory.hxx b/main/sd/source/ui/framework/factories/BasicViewFactory.hxx index 654a398935..513ae5f44d 100644 --- a/main/sd/source/ui/framework/factories/BasicViewFactory.hxx +++ b/main/sd/source/ui/framework/factories/BasicViewFactory.hxx @@ -36,8 +36,8 @@ #include <cppuhelper/compbase2.hxx> #include <osl/mutex.hxx> -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> namespace css = ::com::sun::star; @@ -107,17 +107,17 @@ private: mxConfigurationController; class ViewDescriptor; class ViewShellContainer; - ::boost::scoped_ptr<ViewShellContainer> mpViewShellContainer; + ::std::unique_ptr<ViewShellContainer> mpViewShellContainer; ViewShellBase* mpBase; FrameView* mpFrameView; class ViewCache; - ::boost::shared_ptr<Window> mpWindow; - ::boost::shared_ptr<ViewCache> mpViewCache; + ::std::shared_ptr<Window> mpWindow; + ::std::shared_ptr<ViewCache> mpViewCache; css::uno::Reference<css::drawing::framework::XPane> mxLocalPane; - ::boost::shared_ptr<ViewDescriptor> CreateView ( + ::std::shared_ptr<ViewDescriptor> CreateView ( const css::uno::Reference<css::drawing::framework::XResourceId>& rxViewId, SfxViewFrame& rFrame, ::Window& rWindow, @@ -125,7 +125,7 @@ private: FrameView* pFrameView, const bool bIsCenterView); - ::boost::shared_ptr<ViewShell> CreateViewShell ( + ::std::shared_ptr<ViewShell> CreateViewShell ( const css::uno::Reference<css::drawing::framework::XResourceId>& rxViewId, SfxViewFrame& rFrame, ::Window& rWindow, @@ -133,16 +133,16 @@ private: const bool bIsCenterView); void ActivateCenterView ( - const ::boost::shared_ptr<ViewDescriptor>& rpDescriptor); + const ::std::shared_ptr<ViewDescriptor>& rpDescriptor); void ReleaseView ( - const ::boost::shared_ptr<ViewDescriptor>& rpDescriptor, + const ::std::shared_ptr<ViewDescriptor>& rpDescriptor, bool bDoNotCache = false); bool IsCacheable ( - const ::boost::shared_ptr<ViewDescriptor>& rpDescriptor); + const ::std::shared_ptr<ViewDescriptor>& rpDescriptor); - ::boost::shared_ptr<ViewDescriptor> GetViewFromCache ( + ::std::shared_ptr<ViewDescriptor> GetViewFromCache ( const css::uno::Reference<css::drawing::framework::XResourceId>& rxViewId, const css::uno::Reference<css::drawing::framework::XPane>& rxPane); }; diff --git a/main/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx b/main/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx index da5f64c945..de05e0225c 100644 --- a/main/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx +++ b/main/sd/source/ui/framework/module/ReadOnlyModeObserver.hxx @@ -38,8 +38,8 @@ #include <cppuhelper/compbase2.hxx> #include <tools/link.hxx> #include <boost/function.hpp> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> namespace { @@ -119,7 +119,7 @@ private: ::com::sun::star::uno::Reference<com::sun::star::frame::XDispatch> mxDispatch; class ModifyBroadcaster; - ::boost::scoped_ptr<ModifyBroadcaster> mpBroadcaster; + ::std::unique_ptr<ModifyBroadcaster> mpBroadcaster; /** Listen for the .uno:EditMode command. Returns <TRUE/> when the connection has been established. diff --git a/main/sd/source/ui/inc/SlideSorter.hxx b/main/sd/source/ui/inc/SlideSorter.hxx index db9f58b71b..7698d81299 100644 --- a/main/sd/source/ui/inc/SlideSorter.hxx +++ b/main/sd/source/ui/inc/SlideSorter.hxx @@ -30,8 +30,8 @@ #include <cppuhelper/weakref.hxx> #include <sfx2/viewfrm.hxx> #include <boost/noncopyable.hpp> -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> #include <boost/current_function.hpp> @@ -63,7 +63,7 @@ class Properties; } } } -typedef ::boost::shared_ptr<sd::Window> SharedSdWindow; +typedef ::std::shared_ptr<sd::Window> SharedSdWindow; namespace sd { namespace slidesorter { @@ -105,12 +105,12 @@ public: The little square enclosed by the two scroll bars. Typically the one from the ViewShell. */ - static ::boost::shared_ptr<SlideSorter> CreateSlideSorter ( + static ::std::shared_ptr<SlideSorter> CreateSlideSorter ( ViewShell& rViewShell, - const ::boost::shared_ptr<sd::Window>& rpContentWindow, - const ::boost::shared_ptr<ScrollBar>& rpHorizontalScrollBar, - const ::boost::shared_ptr<ScrollBar>& rpVerticalScrollBar, - const ::boost::shared_ptr<ScrollBarBox>& rpScrollBarBox); + const ::std::shared_ptr<sd::Window>& rpContentWindow, + const ::std::shared_ptr<ScrollBar>& rpHorizontalScrollBar, + const ::std::shared_ptr<ScrollBar>& rpVerticalScrollBar, + const ::std::shared_ptr<ScrollBarBox>& rpScrollBarBox); /** Create a new slide sorter that is losely coupled to the given view shell. The view shell may even be missing. @@ -122,23 +122,23 @@ public: The parent window of the internally created content window and scroll bars. */ - static ::boost::shared_ptr<SlideSorter> CreateSlideSorter ( + static ::std::shared_ptr<SlideSorter> CreateSlideSorter ( ViewShellBase& rBase, ViewShell* pViewShell, ::Window& rParentWindow); /** Return the control of the vertical scroll bar. */ - ::boost::shared_ptr<ScrollBar> GetVerticalScrollBar (void) const; + ::std::shared_ptr<ScrollBar> GetVerticalScrollBar (void) const; /** Return the control of the horizontal scroll bar. */ - ::boost::shared_ptr<ScrollBar> GetHorizontalScrollBar (void) const; + ::std::shared_ptr<ScrollBar> GetHorizontalScrollBar (void) const; /** Return the scroll bar filler that paints the little square that is enclosed by the two scroll bars. */ - ::boost::shared_ptr<ScrollBarBox> GetScrollBarFiller (void) const; + ::std::shared_ptr<ScrollBarBox> GetScrollBarFiller (void) const; /** Return the content window. This is a sibling and is geometrically enclosed by the scroll bars. @@ -190,11 +190,11 @@ public: /** Return a collection of properties that are used throughout the slide sorter. */ - ::boost::shared_ptr<controller::Properties> GetProperties (void) const; + ::std::shared_ptr<controller::Properties> GetProperties (void) const; /** Return the active theme which gives access to colors and fonts. */ - ::boost::shared_ptr<view::Theme> GetTheme (void) const; + ::std::shared_ptr<view::Theme> GetTheme (void) const; protected: /** This virtual method makes it possible to create a specialization of @@ -226,17 +226,17 @@ protected: private: bool mbIsValid; - ::boost::scoped_ptr<controller::SlideSorterController> mpSlideSorterController; - ::boost::scoped_ptr<model::SlideSorterModel> mpSlideSorterModel; - ::boost::scoped_ptr<view::SlideSorterView> mpSlideSorterView; + ::std::unique_ptr<controller::SlideSorterController> mpSlideSorterController; + ::std::unique_ptr<model::SlideSorterModel> mpSlideSorterModel; + ::std::unique_ptr<view::SlideSorterView> mpSlideSorterView; ::com::sun::star::uno::WeakReference<com::sun::star::frame::XController> mxControllerWeak; ViewShell* mpViewShell; ViewShellBase* mpViewShellBase; SharedSdWindow mpContentWindow; bool mbOwnesContentWindow; - ::boost::shared_ptr<ScrollBar> mpHorizontalScrollBar; - ::boost::shared_ptr<ScrollBar> mpVerticalScrollBar; - ::boost::shared_ptr<ScrollBarBox> mpScrollBarBox; + ::std::shared_ptr<ScrollBar> mpHorizontalScrollBar; + ::std::shared_ptr<ScrollBar> mpVerticalScrollBar; + ::std::shared_ptr<ScrollBarBox> mpScrollBarBox; /** Set this flag to <TRUE/> to force a layout before the next paint. */ @@ -245,15 +245,15 @@ private: /** Some slide sorter wide properties that are used in different classes. */ - ::boost::shared_ptr<controller::Properties> mpProperties; - ::boost::shared_ptr<view::Theme> mpTheme; + ::std::shared_ptr<controller::Properties> mpProperties; + ::std::shared_ptr<view::Theme> mpTheme; SlideSorter ( ViewShell& rViewShell, - const ::boost::shared_ptr<sd::Window>& rpContentWindow, - const ::boost::shared_ptr<ScrollBar>& rpHorizontalScrollBar, - const ::boost::shared_ptr<ScrollBar>& rpVerticalScrollBar, - const ::boost::shared_ptr<ScrollBarBox>& rpScrollBarBox); + const ::std::shared_ptr<sd::Window>& rpContentWindow, + const ::std::shared_ptr<ScrollBar>& rpHorizontalScrollBar, + const ::std::shared_ptr<ScrollBar>& rpVerticalScrollBar, + const ::std::shared_ptr<ScrollBarBox>& rpScrollBarBox); SlideSorter ( ViewShellBase& rBase, ViewShell* pViewShell, diff --git a/main/sd/source/ui/inc/ToolBarManager.hxx b/main/sd/source/ui/inc/ToolBarManager.hxx index c94c7292b9..b6c17c3aba 100644 --- a/main/sd/source/ui/inc/ToolBarManager.hxx +++ b/main/sd/source/ui/inc/ToolBarManager.hxx @@ -30,8 +30,8 @@ #include <com/sun/star/frame/XFrame.hpp> #include <sal/types.h> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> #include <boost/enable_shared_from_this.hpp> class SdrView; @@ -68,16 +68,16 @@ class ViewShellManager; in a short time on a view shell switch. */ class ToolBarManager - : public ::boost::enable_shared_from_this<ToolBarManager> + : public ::std::enable_shared_from_this<ToolBarManager> { public: /** Use this method instead of the constructor to create new objects of this class. */ - static ::boost::shared_ptr<ToolBarManager> Create ( + static ::std::shared_ptr<ToolBarManager> Create ( ViewShellBase& rBase, - const ::boost::shared_ptr<tools::EventMultiplexer>& rpMultiplexer, - const ::boost::shared_ptr<ViewShellManager>& rpViewShellManager); + const ::std::shared_ptr<tools::EventMultiplexer>& rpMultiplexer, + const ::std::shared_ptr<ViewShellManager>& rpViewShellManager); ~ToolBarManager (void); @@ -251,11 +251,11 @@ public: bar operations are made in a row. */ class UpdateLock { public: - UpdateLock(const ::boost::shared_ptr<ToolBarManager>& rpManager) + UpdateLock(const ::std::shared_ptr<ToolBarManager>& rpManager) : mpManager(rpManager) { mpManager->LockUpdate(); } ~UpdateLock(void) { mpManager->UnlockUpdate(); } private: - ::boost::shared_ptr<ToolBarManager> mpManager; + ::std::shared_ptr<ToolBarManager> mpManager; }; friend class UpdateLock; @@ -263,7 +263,7 @@ public: private: class Implementation; - ::boost::scoped_ptr<Implementation> mpImpl; + ::std::unique_ptr<Implementation> mpImpl; /** The ViewShellBase is used to get the XLayoutManager and to determine the plug in mode. diff --git a/main/sd/source/ui/inc/ViewShellBase.hxx b/main/sd/source/ui/inc/ViewShellBase.hxx index a1d4612fb2..22d0888aa4 100644 --- a/main/sd/source/ui/inc/ViewShellBase.hxx +++ b/main/sd/source/ui/inc/ViewShellBase.hxx @@ -32,8 +32,8 @@ #include <sfx2/viewsh.hxx> #include <sfx2/viewfac.hxx> #include <memory> -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> #include <set> @@ -88,13 +88,13 @@ public: */ virtual void LateInit (const ::rtl::OUString& rsDefaultView); - ::boost::shared_ptr<ViewShellManager> GetViewShellManager (void) const; + ::std::shared_ptr<ViewShellManager> GetViewShellManager (void) const; /** Return the main view shell stacked on the called ViewShellBase object. This is usually the view shell displayed in the center pane. */ - ::boost::shared_ptr<ViewShell> GetMainViewShell (void) const; + ::std::shared_ptr<ViewShell> GetMainViewShell (void) const; /** When given a view frame this static method returns the corresponding sd::ViewShellBase object. @@ -209,18 +209,18 @@ public: events from various sources. This method must not be called before LateInit() has terminated. */ - ::boost::shared_ptr<tools::EventMultiplexer> GetEventMultiplexer (void); + ::std::shared_ptr<tools::EventMultiplexer> GetEventMultiplexer (void); /** returns the complete area of the current view relative to the frame window */ const Rectangle& getClientRectangle() const; - ::boost::shared_ptr<UpdateLockManager> GetUpdateLockManager (void) const; + ::std::shared_ptr<UpdateLockManager> GetUpdateLockManager (void) const; - ::boost::shared_ptr<ToolBarManager> GetToolBarManager (void) const; + ::std::shared_ptr<ToolBarManager> GetToolBarManager (void) const; - ::boost::shared_ptr<FormShellManager> GetFormShellManager (void) const; + ::std::shared_ptr<FormShellManager> GetFormShellManager (void) const; DrawController& GetDrawController (void) const; @@ -245,7 +245,7 @@ protected: private: class Implementation; - ::boost::scoped_ptr<Implementation> mpImpl; + ::std::unique_ptr<Implementation> mpImpl; DrawDocShell* mpDocShell; SdDrawDocument* mpDocument; diff --git a/main/sd/source/ui/inc/ViewTabBar.hxx b/main/sd/source/ui/inc/ViewTabBar.hxx index c8971a2c9a..b9a410fd46 100644 --- a/main/sd/source/ui/inc/ViewTabBar.hxx +++ b/main/sd/source/ui/inc/ViewTabBar.hxx @@ -39,8 +39,8 @@ #include "MutexOwner.hxx" #include <vector> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> namespace sd { namespace tools { class EventMultiplexerEvent; @@ -81,7 +81,7 @@ public: virtual void SAL_CALL disposing (void); - ::boost::shared_ptr< ::TabControl> GetTabControl (void) const; + ::std::shared_ptr< ::TabControl> GetTabControl (void) const; bool ActivatePage (void); @@ -159,14 +159,14 @@ public: GetTabBarButtons (void); private: - ::boost::shared_ptr< ::TabControl> mpTabControl; + ::std::shared_ptr< ::TabControl> mpTabControl; ::com::sun::star::uno::Reference< ::com::sun::star::frame::XController> mxController; ::com::sun::star::uno::Reference< ::com::sun::star::drawing::framework::XConfigurationController> mxConfigurationController; typedef ::std::vector<com::sun::star::drawing::framework::TabBarButton> TabBarButtonList; TabBarButtonList maTabBarButtons; - ::boost::scoped_ptr<TabPage> mpTabPage; + ::std::unique_ptr<TabPage> mpTabPage; ::com::sun::star::uno::Reference< ::com::sun::star::drawing::framework::XResourceId> mxViewTabBarId; ViewShellBase* mpViewShellBase; diff --git a/main/sd/source/ui/inc/framework/ConfigurationController.hxx b/main/sd/source/ui/inc/framework/ConfigurationController.hxx index 75645c2160..be39aa0e09 100644 --- a/main/sd/source/ui/inc/framework/ConfigurationController.hxx +++ b/main/sd/source/ui/inc/framework/ConfigurationController.hxx @@ -40,8 +40,8 @@ #include <tools/link.hxx> #include <rtl/ref.hxx> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> #include <boost/noncopyable.hpp> namespace css = ::com::sun::star; @@ -193,7 +193,7 @@ public: private: class Implementation; - ::boost::scoped_ptr<Implementation> mpImplementation; + ::std::unique_ptr<Implementation> mpImplementation; bool mbIsDisposed; /** When the called object has already been disposed this method throws diff --git a/main/sd/source/ui/inc/framework/FrameworkHelper.hxx b/main/sd/source/ui/inc/framework/FrameworkHelper.hxx index 14e8f73443..a5cbe7bdc0 100644 --- a/main/sd/source/ui/inc/framework/FrameworkHelper.hxx +++ b/main/sd/source/ui/inc/framework/FrameworkHelper.hxx @@ -32,8 +32,8 @@ #include <com/sun/star/drawing/framework/XView.hpp> #include <com/sun/star/lang/XEventListener.hpp> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> #include <boost/enable_shared_from_this.hpp> #include <boost/function.hpp> #include <map> @@ -64,7 +64,7 @@ namespace sd { namespace framework { controllers called by it throws a DisposedException. */ class FrameworkHelper - : public ::boost::enable_shared_from_this<FrameworkHelper>, + : public ::std::enable_shared_from_this<FrameworkHelper>, public SdGlobalResource { public: @@ -118,9 +118,9 @@ public: ViewShellBase. If such an object does not yet exist, a new one is created. */ - static ::boost::shared_ptr<FrameworkHelper> Instance (ViewShellBase& rBase); + static ::std::shared_ptr<FrameworkHelper> Instance (ViewShellBase& rBase); - static ::boost::shared_ptr<FrameworkHelper> Instance ( + static ::std::shared_ptr<FrameworkHelper> Instance ( const cssu::Reference<css::frame::XController>& rxController); /** Mark the FrameworkHelper object for the given ViewShellBase as @@ -157,7 +157,7 @@ public: When the ViewShell pointer can not be inferred from the given reference then an empty pointer is returned. */ - static ::boost::shared_ptr<ViewShell> GetViewShell ( + static ::std::shared_ptr<ViewShell> GetViewShell ( const cssu::Reference<cssdf::XView>& rxView); typedef ::boost::function<bool(const cssdf::ConfigurationChangeEvent&)> @@ -184,7 +184,7 @@ public: of the involved objects does not support XUnoTunnel (where necessary). */ - ::boost::shared_ptr<ViewShell> GetViewShell (const ::rtl::OUString& rsPaneURL); + ::std::shared_ptr<ViewShell> GetViewShell (const ::rtl::OUString& rsPaneURL); /** Return a reference to the view that is displayed in the specified pane. See GetViewShell () for a variant that returns a ViewShell @@ -364,13 +364,13 @@ public: private: typedef ::std::map< ViewShellBase*, - ::boost::shared_ptr<FrameworkHelper> > InstanceMap; + ::std::shared_ptr<FrameworkHelper> > InstanceMap; /** The instance map holds (at least) one FrameworkHelper instance for every ViewShellBase object. */ static InstanceMap maInstanceMap; class ViewURLMap; - static ::boost::scoped_ptr<ViewURLMap> mpViewURLMap; + static ::std::unique_ptr<ViewURLMap> mpViewURLMap; ViewShellBase& mrBase; cssu::Reference<cssdf::XConfigurationController> diff --git a/main/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx b/main/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx index ac608e7193..b12f8f0a2b 100644 --- a/main/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx +++ b/main/sd/source/ui/inc/taskpane/ToolPanelViewShell.hxx @@ -33,8 +33,8 @@ #include <sfx2/viewfac.hxx> #include <sfx2/dockwin.hxx> -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> class PopupMenu; @@ -131,9 +131,9 @@ public: ); private: - ::boost::scoped_ptr< ToolPanelViewShell_Impl > mpImpl; + ::std::unique_ptr< ToolPanelViewShell_Impl > mpImpl; - ::boost::shared_ptr<TaskPaneShellManager> mpSubShellManager; + ::std::shared_ptr<TaskPaneShellManager> mpSubShellManager; /** The id of the menu in the menu bar/tool box of the parent docking window. diff --git a/main/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx b/main/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx index 590589e1ab..89ea42a273 100644 --- a/main/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx +++ b/main/sd/source/ui/slidesorter/cache/SlsBitmapCache.hxx @@ -28,8 +28,8 @@ class SdrPage; #include <vcl/bitmapex.hxx> #include <osl/mutex.hxx> -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> #include <unordered_map> namespace sd { namespace slidesorter { namespace cache { @@ -176,12 +176,12 @@ public: */ void Compress ( const CacheKey& rKey, - const ::boost::shared_ptr<BitmapCompressor>& rpCompressor); + const ::std::shared_ptr<BitmapCompressor>& rpCompressor); private: mutable ::osl::Mutex maMutex; - ::boost::scoped_ptr<CacheBitmapContainer> mpBitmapContainer; + ::std::unique_ptr<CacheBitmapContainer> mpBitmapContainer; /** Total size of bytes that are occupied by bitmaps in the cache for whom the slides are currently not inside the visible area. diff --git a/main/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx b/main/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx index d19d08c099..08ef4c8d8e 100644 --- a/main/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx +++ b/main/sd/source/ui/slidesorter/cache/SlsGenericPageCache.hxx @@ -26,7 +26,8 @@ #include "SlideSorter.hxx" #include "SlsRequestQueue.hxx" -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> namespace sd { namespace slidesorter { namespace cache { @@ -138,11 +139,11 @@ public: void Resume (void); private: - ::boost::shared_ptr<BitmapCache> mpBitmapCache; + ::std::shared_ptr<BitmapCache> mpBitmapCache; RequestQueue maRequestQueue; - ::boost::scoped_ptr<QueueProcessor> mpQueueProcessor; + ::std::unique_ptr<QueueProcessor> mpQueueProcessor; SharedCacheContext mpCacheContext; diff --git a/main/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx b/main/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx index aab965b5d8..efd6270002 100644 --- a/main/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx +++ b/main/sd/source/ui/slidesorter/inc/controller/SlideSorterController.hxx @@ -34,6 +34,7 @@ #include <tools/link.hxx> #include <tools/gen.hxx> #include <comphelper/implementationreference.hxx> +#include <memory> namespace sd { namespace slidesorter { class SlideSorter; @@ -123,10 +124,10 @@ public: */ ScrollBarManager& GetScrollBarManager (void); - ::boost::shared_ptr<CurrentSlideManager> GetCurrentSlideManager (void) const; - ::boost::shared_ptr<SlotManager> GetSlotManager (void) const; - ::boost::shared_ptr<SelectionManager> GetSelectionManager (void) const; - ::boost::shared_ptr<InsertionIndicatorHandler> GetInsertionIndicatorHandler (void) const; + ::std::shared_ptr<CurrentSlideManager> GetCurrentSlideManager (void) const; + ::std::shared_ptr<SlotManager> GetSlotManager (void) const; + ::std::shared_ptr<SelectionManager> GetSelectionManager (void) const; + ::std::shared_ptr<InsertionIndicatorHandler> GetInsertionIndicatorHandler (void) const; /** This method forwards the call to the SlideSorterView and executes pending operations like moving selected pages into the visible area. @@ -231,7 +232,7 @@ public: /** Return an Animator object. */ - ::boost::shared_ptr<Animator> GetAnimator (void) const; + ::std::shared_ptr<Animator> GetAnimator (void) const; VisibleAreaManager& GetVisibleAreaManager (void) const; @@ -242,16 +243,16 @@ private: SlideSorter& mrSlideSorter; model::SlideSorterModel& mrModel; view::SlideSorterView& mrView; - ::boost::scoped_ptr<PageSelector> mpPageSelector; - ::boost::scoped_ptr<FocusManager> mpFocusManager; - ::boost::shared_ptr<SlotManager> mpSlotManager; - ::boost::scoped_ptr<controller::Clipboard> mpClipboard; - ::boost::scoped_ptr<ScrollBarManager> mpScrollBarManager; - mutable ::boost::shared_ptr<CurrentSlideManager> mpCurrentSlideManager; - ::boost::shared_ptr<SelectionManager> mpSelectionManager; - ::boost::shared_ptr<InsertionIndicatorHandler> mpInsertionIndicatorHandler; - ::boost::shared_ptr<Animator> mpAnimator; - ::boost::scoped_ptr<VisibleAreaManager> mpVisibleAreaManager; + ::std::unique_ptr<PageSelector> mpPageSelector; + ::std::unique_ptr<FocusManager> mpFocusManager; + ::std::shared_ptr<SlotManager> mpSlotManager; + ::std::unique_ptr<controller::Clipboard> mpClipboard; + ::std::unique_ptr<ScrollBarManager> mpScrollBarManager; + mutable ::std::shared_ptr<CurrentSlideManager> mpCurrentSlideManager; + ::std::shared_ptr<SelectionManager> mpSelectionManager; + ::std::shared_ptr<InsertionIndicatorHandler> mpInsertionIndicatorHandler; + ::std::shared_ptr<Animator> mpAnimator; + ::std::unique_ptr<VisibleAreaManager> mpVisibleAreaManager; // The listener listens to UNO events and thus is a UNO object. // For proper life time management and at the same time free access to diff --git a/main/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx b/main/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx index 73e759dc29..437e8c1378 100644 --- a/main/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx +++ b/main/sd/source/ui/slidesorter/inc/controller/SlsAnimator.hxx @@ -32,8 +32,8 @@ #include <vector> #include <boost/function.hpp> #include <boost/noncopyable.hpp> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> namespace sd { namespace slidesorter { namespace controller { @@ -105,11 +105,11 @@ private: Timer maTimer; bool mbIsDisposed; class Animation; - typedef ::std::vector<boost::shared_ptr<Animation> > AnimationList; + typedef ::std::vector<std::shared_ptr<Animation> > AnimationList; AnimationList maAnimations; ::canvas::tools::ElapsedTime maElapsedTime; - ::boost::scoped_ptr<view::SlideSorterView::DrawLock> mpDrawLock; + ::std::unique_ptr<view::SlideSorterView::DrawLock> mpDrawLock; AnimationId mnNextAnimationId; diff --git a/main/sd/source/ui/slidesorter/inc/view/SlsButtonBar.hxx b/main/sd/source/ui/slidesorter/inc/view/SlsButtonBar.hxx index 56a16b0658..437ff05e03 100644 --- a/main/sd/source/ui/slidesorter/inc/view/SlsButtonBar.hxx +++ b/main/sd/source/ui/slidesorter/inc/view/SlsButtonBar.hxx @@ -29,7 +29,8 @@ #include <rtl/ustring.hxx> #include <vcl/bitmapex.hxx> #include <vcl/bmpacc.hxx> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> namespace sd { namespace slidesorter { class SlideSorter; @@ -41,7 +42,7 @@ namespace sd { namespace slidesorter { namespace view { class Theme; class Button; -typedef ::boost::shared_ptr<Button> SharedButton; +typedef ::std::shared_ptr<Button> SharedButton; /** This is a container of buttons and a coordinating controller. The last means that it receives mouse events and forwards them to @@ -85,7 +86,7 @@ public: @return Returns an empty pointer when the given index is not valid. */ - ::boost::shared_ptr<Button> GetButton ( + ::std::shared_ptr<Button> GetButton ( const bool bIsExcluded, const sal_Int32 nIndex) const; @@ -157,15 +158,15 @@ private: Point maBackgroundLocation; model::SharedPageDescriptor mpDescriptor; bool mbIsExcluded; - boost::shared_ptr<Button> mpButtonUnderMouse; + std::shared_ptr<Button> mpButtonUnderMouse; // The button on which the mouse button was pressed. - boost::shared_ptr<Button> mpDownButton; + std::shared_ptr<Button> mpDownButton; ::std::vector<SharedButton> maRegularButtons; ::std::vector<SharedButton> maExcludedButtons; BitmapEx maNormalBackground; BitmapEx maButtonDownBackground; bool mbIsMouseOverBar; - ::boost::scoped_ptr<BackgroundTheme> mpBackgroundTheme; + ::std::unique_ptr<BackgroundTheme> mpBackgroundTheme; int mnLockCount; /** Remember the specified page. If it differs from mpDescriptor then @@ -223,7 +224,7 @@ public: OutputDevice& rDevice, const Point aOffset, const double nAlpha, - const ::boost::shared_ptr<Theme>& rpTheme) const = 0; + const ::std::shared_ptr<Theme>& rpTheme) const = 0; virtual void ProcessClick (const model::SharedPageDescriptor& rpDescriptor) = 0; /** Return the bounding box of the layouted button. @@ -269,7 +270,7 @@ public: OutputDevice& rDevice, const Point aOffset, const double nAlpha, - const ::boost::shared_ptr<Theme>& rpTheme) const; + const ::std::shared_ptr<Theme>& rpTheme) const; virtual Size GetSize (void) const; virtual Size GetSize (const IconSize eIconSize) const; @@ -297,7 +298,7 @@ public: OutputDevice& rDevice, const Point aOffset, const double nAlpha, - const ::boost::shared_ptr<Theme>& rpTheme) const; + const ::std::shared_ptr<Theme>& rpTheme) const; virtual Size GetSize (void) const; virtual Size GetSize (const IconSize eIconSize) const; diff --git a/main/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx b/main/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx index 4538a2d757..10a301d355 100644 --- a/main/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx +++ b/main/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx @@ -28,7 +28,8 @@ #include "model/SlsPageDescriptor.hxx" #include "view/SlsLayouter.hxx" #include "view/SlsTheme.hxx" -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> namespace sd { namespace slidesorter { namespace cache { class PageCache; @@ -58,7 +59,7 @@ public: the given theme is the same object as the one already in use by this painter everything that depends on the theme is updated. */ - void SetTheme (const ::boost::shared_ptr<view::Theme>& rpTheme); + void SetTheme (const ::std::shared_ptr<view::Theme>& rpTheme); /** Return a preview bitmap for the given page descriptor. When the page is excluded from the show then the preview is marked @@ -77,13 +78,13 @@ public: private: const Layouter& mrLayouter; - ::boost::shared_ptr<PageObjectLayouter> mpPageObjectLayouter; - ::boost::shared_ptr<cache::PageCache> mpCache; - ::boost::shared_ptr<controller::Properties> mpProperties; - ::boost::shared_ptr<view::Theme> mpTheme; - ::boost::shared_ptr<Font> mpPageNumberFont; - ::boost::scoped_ptr<FramePainter> mpShadowPainter; - ::boost::scoped_ptr<FramePainter> mpFocusBorderPainter; + ::std::shared_ptr<PageObjectLayouter> mpPageObjectLayouter; + ::std::shared_ptr<cache::PageCache> mpCache; + ::std::shared_ptr<controller::Properties> mpProperties; + ::std::shared_ptr<view::Theme> mpTheme; + ::std::shared_ptr<Font> mpPageNumberFont; + ::std::unique_ptr<FramePainter> mpShadowPainter; + ::std::unique_ptr<FramePainter> mpFocusBorderPainter; Bitmap maNormalBackground; Bitmap maSelectionBackground; Bitmap maFocusedSelectionBackground; diff --git a/main/sd/source/ui/slidesorter/shell/SlideSorterService.hxx b/main/sd/source/ui/slidesorter/shell/SlideSorterService.hxx index 379c4310b0..ba54c77aca 100644 --- a/main/sd/source/ui/slidesorter/shell/SlideSorterService.hxx +++ b/main/sd/source/ui/slidesorter/shell/SlideSorterService.hxx @@ -36,8 +36,8 @@ #include <cppuhelper/compbase3.hxx> #include <cppuhelper/propshlp.hxx> #include <boost/noncopyable.hpp> -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> namespace css = ::com::sun::star; @@ -158,10 +158,10 @@ public: virtual void SAL_CALL setIsShowFocus (sal_Bool bIsShowFocus); private: - ::boost::shared_ptr<SlideSorter> mpSlideSorter; + ::std::shared_ptr<SlideSorter> mpSlideSorter; css::uno::Reference<css::drawing::framework::XResourceId> mxViewId; css::uno::Reference<css::awt::XWindow> mxParentWindow; - ::boost::scoped_ptr<cppu::IPropertyArrayHelper> mpPropertyArrayHelper; + ::std::unique_ptr<cppu::IPropertyArrayHelper> mpPropertyArrayHelper; void Resize (void); diff --git a/main/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx b/main/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx index f7b759f033..26fe140ba0 100644 --- a/main/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx +++ b/main/sd/source/ui/slidesorter/view/SlsLayeredDevice.hxx @@ -32,8 +32,8 @@ #include <vcl/virdev.hxx> #include <boost/noncopyable.hpp> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> #include <boost/enable_shared_from_this.hpp> #include <vector> @@ -46,7 +46,7 @@ namespace sd { namespace slidesorter { namespace view { Each layer may contain any number of painters. */ class LayeredDevice - : public ::boost::enable_shared_from_this<LayeredDevice> + : public ::std::enable_shared_from_this<LayeredDevice> { public: @@ -81,8 +81,8 @@ public: private: SharedSdWindow mpTargetWindow; class LayerContainer; - ::boost::scoped_ptr<LayerContainer> mpLayers; - ::boost::scoped_ptr<VirtualDevice> mpBackBuffer; + ::std::unique_ptr<LayerContainer> mpLayers; + ::std::unique_ptr<VirtualDevice> mpBackBuffer; MapMode maSavedMapMode; void RepaintRectangle (const Rectangle& rRepaintRectangle); diff --git a/main/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx b/main/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx index 52352585b8..e8c06724f8 100644 --- a/main/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx +++ b/main/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx @@ -40,7 +40,8 @@ #include <vcl/svapp.hxx> #include <vcl/vclenum.hxx> #include <vcl/virdev.hxx> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> using namespace ::drawinglayer::primitive2d; @@ -206,7 +207,7 @@ void PageObjectPainter::InvalidateBitmaps (void) -void PageObjectPainter::SetTheme (const ::boost::shared_ptr<view::Theme>& rpTheme) +void PageObjectPainter::SetTheme (const ::std::shared_ptr<view::Theme>& rpTheme) { mpTheme = rpTheme; NotifyResize(true); @@ -279,7 +280,7 @@ Bitmap PageObjectPainter::CreateMarkedPreview ( const BitmapEx& rOverlay, const OutputDevice* pReferenceDevice) const { - ::boost::scoped_ptr<VirtualDevice> pDevice; + ::std::unique_ptr<VirtualDevice> pDevice; if (pReferenceDevice != NULL) pDevice.reset(new VirtualDevice(*pReferenceDevice)); else diff --git a/main/sd/source/ui/view/DocumentRenderer.cxx b/main/sd/source/ui/view/DocumentRenderer.cxx index d7a077cad0..889737c1b3 100644 --- a/main/sd/source/ui/view/DocumentRenderer.cxx +++ b/main/sd/source/ui/view/DocumentRenderer.cxx @@ -58,6 +58,7 @@ #include <unotools/moduleoptions.hxx> #include <vector> +#include <memory> using namespace ::com::sun::star; using namespace ::com::sun::star::uno; @@ -296,7 +297,7 @@ namespace { const bool mbAreAllPagesSelected; const bool mbIsShapeSelection; const sal_Int32 mnCurrentPageIndex; - ::boost::scoped_ptr<MultiSelection> mpSelectedPages; + ::std::unique_ptr<MultiSelection> mpSelectedPages; }; /** A collection of values that helps to reduce the number of arguments @@ -309,7 +310,7 @@ namespace { PrintInfo ( const Printer* pPrinter, const OUString& rsPrinterSelection, - const ::boost::shared_ptr<ViewShell> pView) + const ::std::shared_ptr<ViewShell> pView) : mpPrinter(pPrinter), mnDrawMode(DRAWMODE_DEFAULT), msTimeDate(), @@ -1204,7 +1205,7 @@ namespace { } private: - ::boost::scoped_ptr<OutlinerParaObject> mpParaObject; + ::std::unique_ptr<OutlinerParaObject> mpParaObject; }; } @@ -1346,14 +1347,14 @@ public: Printer& rPrinter (*mpPrinter); - ::boost::shared_ptr<ViewShell> pViewShell (mrBase.GetMainViewShell()); + ::std::shared_ptr<ViewShell> pViewShell (mrBase.GetMainViewShell()); if ( ! pViewShell) return; SdDrawDocument* pDocument = pViewShell->GetDoc(); OSL_ASSERT(pDocument!=NULL); - ::boost::shared_ptr<DrawViewShell> pDrawViewShell( + ::std::shared_ptr<DrawViewShell> pDrawViewShell( ::boost::dynamic_pointer_cast<DrawViewShell>(mrBase.GetMainViewShell())); if ( ! mpPrintView) @@ -1362,7 +1363,7 @@ public: if (nIndex<0 || sal::static_int_cast<sal_uInt32>(nIndex)>=maPrinterPages.size()) return; - const ::boost::shared_ptr<PrinterPage> pPage (maPrinterPages[nIndex]); + const ::std::shared_ptr<PrinterPage> pPage (maPrinterPages[nIndex]); OSL_ASSERT(pPage); if ( ! pPage) return; @@ -1423,9 +1424,9 @@ private: bool mbIsDisposed; Printer* mpPrinter; Size maPrinterPageSizePixel; - ::boost::scoped_ptr<PrintOptions> mpOptions; - ::std::vector< ::boost::shared_ptr< ::sd::PrinterPage> > maPrinterPages; - ::boost::scoped_ptr<DrawView> mpPrintView; + ::std::unique_ptr<PrintOptions> mpOptions; + ::std::vector< ::std::shared_ptr< ::sd::PrinterPage> > maPrinterPages; + ::std::unique_ptr<DrawView> mpPrintView; bool mbHasOrientationWarningBeenShown; ::std::vector<sal_Int32> maSlidesPerPage; awt::Size maPrintSize; @@ -1845,7 +1846,7 @@ private: } maPrinterPages.push_back( - ::boost::shared_ptr<PrinterPage>( + ::std::shared_ptr<PrinterPage>( new OutlinerPrinterPage( pOutliner->CreateParaObject(), aMap, @@ -1925,7 +1926,7 @@ private: aMap.SetOrigin(Point()); } - ::boost::shared_ptr<ViewShell> pViewShell (mrBase.GetMainViewShell()); + ::std::shared_ptr<ViewShell> pViewShell (mrBase.GetMainViewShell()); pViewShell->WriteFrameViewData(); // Count page shapes. @@ -1964,7 +1965,7 @@ private: if (!aPageIndices.empty() && (aPageIndices.size() == nShapeCount || nIndex==nCount)) { maPrinterPages.push_back( - ::boost::shared_ptr<PrinterPage>( + ::std::shared_ptr<PrinterPage>( new HandoutPrinterPage( nHandoutPageIndex++, aPageIndices, @@ -2020,7 +2021,7 @@ private: const PageKind ePageKind, PrintInfo& rInfo) { - ::boost::shared_ptr<ViewShell> pViewShell (mrBase.GetMainViewShell()); + ::std::shared_ptr<ViewShell> pViewShell (mrBase.GetMainViewShell()); pViewShell->WriteFrameViewData(); Point aPtZero; @@ -2200,7 +2201,7 @@ private: else aSecondOffset.Y() += aAdjustedPrintSize.Height() / 2; maPrinterPages.push_back( - ::boost::shared_ptr<PrinterPage>( + ::std::shared_ptr<PrinterPage>( new BookletPrinterPage( aPair.first, aPair.second, @@ -2236,7 +2237,7 @@ private: nPaperBin = rInfo.mpPrinter->GetPaperBin(); maPrinterPages.push_back( - ::boost::shared_ptr<PrinterPage>( + ::std::shared_ptr<PrinterPage>( new TiledPrinterPage( sal::static_int_cast<sal_uInt16>(nPageIndex), ePageKind, @@ -2292,7 +2293,7 @@ private: aMap.SetOrigin(Point(0,0)); #endif maPrinterPages.push_back( - ::boost::shared_ptr<PrinterPage>( + ::std::shared_ptr<PrinterPage>( new RegularPrinterPage( sal::static_int_cast<sal_uInt16>(nPageIndex), ePageKind, @@ -2332,7 +2333,7 @@ private: { aMap.SetOrigin(aPageOrigin); maPrinterPages.push_back( - ::boost::shared_ptr<PrinterPage>( + ::std::shared_ptr<PrinterPage>( new RegularPrinterPage( sal::static_int_cast<sal_uInt16>(nPageIndex), ePageKind, diff --git a/main/sdext/source/pdfimport/wrapper/wrapper.cxx b/main/sdext/source/pdfimport/wrapper/wrapper.cxx index 11ced3b346..9f2909a96f 100644 --- a/main/sdext/source/pdfimport/wrapper/wrapper.cxx +++ b/main/sdext/source/pdfimport/wrapper/wrapper.cxx @@ -61,7 +61,7 @@ #include <boost/bind.hpp> #include <boost/preprocessor/stringize.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> #include <boost/scoped_array.hpp> #include <unordered_map> @@ -919,7 +919,7 @@ static bool checkEncryption( const rtl::OUString& aPDFFile = rtl::OUStringToOString( i_rPath, osl_getThreadTextEncoding() ); pdfparse::PDFReader aParser; - boost::scoped_ptr<pdfparse::PDFEntry> pEntry( aParser.read( aPDFFile.getStr() )); + std::unique_ptr<pdfparse::PDFEntry> pEntry( aParser.read( aPDFFile.getStr() )); if( pEntry ) { pdfparse::PDFFile* pPDFFile = dynamic_cast<pdfparse::PDFFile*>(pEntry.get()); diff --git a/main/sdext/source/presenter/PresenterAnimation.hxx b/main/sdext/source/presenter/PresenterAnimation.hxx index 49bdbd854b..88b96448b9 100644 --- a/main/sdext/source/presenter/PresenterAnimation.hxx +++ b/main/sdext/source/presenter/PresenterAnimation.hxx @@ -27,8 +27,8 @@ #include <sal/types.h> #include <boost/function.hpp> #include <boost/noncopyable.hpp> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> #include <vector> namespace sdext { namespace presenter { @@ -110,15 +110,15 @@ private: const sal_uInt64 mnStartTime; const sal_uInt64 mnTotalDuration; const sal_uInt64 mnStepDuration; - ::boost::scoped_ptr<std::vector<Callback> > mpStartCallbacks; - ::boost::scoped_ptr<std::vector<Callback> > mpEndCallbacks; + ::std::unique_ptr<std::vector<Callback> > mpStartCallbacks; + ::std::unique_ptr<std::vector<Callback> > mpEndCallbacks; }; sal_uInt64 GetCurrentTime (void); inline sal_uInt32 GetSeconds (const sal_uInt64 nTime) { return sal_uInt32(nTime / 1000); } inline sal_uInt32 GetNanoSeconds (const sal_uInt64 nTime) { return sal_uInt32((nTime % 1000) * 1000000); } -typedef ::boost::shared_ptr<PresenterAnimation> SharedPresenterAnimation; +typedef ::std::shared_ptr<PresenterAnimation> SharedPresenterAnimation; } } // end of namespace ::sdext::presenter diff --git a/main/sdext/source/presenter/PresenterPaneBorderPainter.hxx b/main/sdext/source/presenter/PresenterPaneBorderPainter.hxx index 4297f5aa36..a4447e5add 100644 --- a/main/sdext/source/presenter/PresenterPaneBorderPainter.hxx +++ b/main/sdext/source/presenter/PresenterPaneBorderPainter.hxx @@ -34,8 +34,8 @@ #include <cppuhelper/basemutex.hxx> #include <cppuhelper/compbase1.hxx> #include <boost/noncopyable.hpp> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> namespace css = ::com::sun::star; @@ -96,7 +96,7 @@ public: bool HasTheme (void) const; - void SetTheme (const ::boost::shared_ptr<PresenterTheme>& rpTheme); + void SetTheme (const ::std::shared_ptr<PresenterTheme>& rpTheme); class Renderer; @@ -132,8 +132,8 @@ public: private: css::uno::Reference<css::uno::XComponentContext> mxContext; - ::boost::shared_ptr<PresenterTheme> mpTheme; - ::boost::scoped_ptr<Renderer> mpRenderer; + ::std::shared_ptr<PresenterTheme> mpTheme; + ::std::unique_ptr<Renderer> mpRenderer; /** When the theme for the border has not yet been loaded then try again when this method is called. diff --git a/main/sfx2/source/sidebar/Panel.hxx b/main/sfx2/source/sidebar/Panel.hxx index a6c73064f6..c991c17178 100644 --- a/main/sfx2/source/sidebar/Panel.hxx +++ b/main/sfx2/source/sidebar/Panel.hxx @@ -29,8 +29,7 @@ #include <com/sun/star/ui/XSidebarPanel.hpp> #include <boost/function.hpp> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> #include <vector> namespace css = ::com::sun::star; @@ -76,7 +75,7 @@ public: private: const ::rtl::OUString msPanelId; - ::boost::scoped_ptr<PanelTitleBar> mpTitleBar; + ::std::unique_ptr<PanelTitleBar> mpTitleBar; const bool mbIsTitleBarOptional; cssu::Reference<css::ui::XUIElement> mxElement; cssu::Reference<css::ui::XSidebarPanel> mxPanelComponent; @@ -84,7 +83,7 @@ private: const ::boost::function<void(void)> maDeckLayoutTrigger; const ::boost::function<Context(void)> maContextAccess; }; -typedef ::boost::shared_ptr<Panel> SharedPanel; +typedef ::std::shared_ptr<Panel> SharedPanel; typedef ::std::vector<SharedPanel> SharedPanelContainer; diff --git a/main/sfx2/source/sidebar/TabBar.hxx b/main/sfx2/source/sidebar/TabBar.hxx index 399399a510..7f6b019fb9 100644 --- a/main/sfx2/source/sidebar/TabBar.hxx +++ b/main/sfx2/source/sidebar/TabBar.hxx @@ -31,7 +31,7 @@ #include <com/sun/star/frame/XFrame.hpp> #include <boost/function.hpp> #include <boost/tuple/tuple.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> class Button; class CheckBox; @@ -99,12 +99,12 @@ public: private: cssu::Reference<css::frame::XFrame> mxFrame; - ::boost::scoped_ptr<CheckBox> mpMenuButton; + ::std::unique_ptr<CheckBox> mpMenuButton; class Item { public: DECL_LINK(HandleClick, Button*); - ::boost::shared_ptr<RadioButton> mpButton; + ::std::shared_ptr<RadioButton> mpButton; ::rtl::OUString msDeckId; ::boost::function<void(const ::rtl::OUString&rsDeckId)> maDeckActivationFunctor; bool mbIsHidden; @@ -122,7 +122,7 @@ private: void Layout (void); void UpdateButtonIcons (void); - ::boost::shared_ptr<PopupMenu> CreatePopupMenu (void) const; + ::std::shared_ptr<PopupMenu> CreatePopupMenu (void) const; void ShowPopupMenu (void) const; DECL_LINK(OnToolboxClicked, void*); diff --git a/main/slideshow/source/engine/shapes/shapeimporter.cxx b/main/slideshow/source/engine/shapes/shapeimporter.cxx index ada45cb6b9..d125fe6dc4 100644 --- a/main/slideshow/source/engine/shapes/shapeimporter.cxx +++ b/main/slideshow/source/engine/shapes/shapeimporter.cxx @@ -60,8 +60,8 @@ #include "tools.hxx" #include "slideshowcontext.hxx" -#include <boost/shared_ptr.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> using namespace com::sun::star; @@ -125,7 +125,7 @@ bool importShapeGraphic( // no special string found, graphic must be // external. Load via GraphicIm porter INetURLObject aTmp( aURL ); - boost::scoped_ptr<SvStream> pGraphicStream( + std::unique_ptr<SvStream> pGraphicStream( utl::UcbStreamHelper::CreateStream( aTmp.GetMainURL( INetURLObject::NO_DECODE ), STREAM_READ ) ); diff --git a/main/slideshow/source/inc/screenupdater.hxx b/main/slideshow/source/inc/screenupdater.hxx index 8572f271a4..c80fc6f28c 100644 --- a/main/slideshow/source/inc/screenupdater.hxx +++ b/main/slideshow/source/inc/screenupdater.hxx @@ -27,7 +27,8 @@ #include "viewupdate.hxx" #include "unoviewcontainer.hxx" #include <boost/noncopyable.hpp> -#include <boost/scoped_ptr.hpp> +#include <memory> +#include <memory> /* Definition of ScreenUpdater class */ @@ -113,7 +114,7 @@ namespace slideshow locked. When <FALSE/> then Activate() has to be called in order to lock the lock. */ - ::boost::shared_ptr<UpdateLock> createLock (const bool bStartLocked); + ::std::shared_ptr<UpdateLock> createLock (const bool bStartLocked); /** Lock updates to prevent intermediate repaints. */ @@ -126,7 +127,7 @@ namespace slideshow private: struct ImplScreenUpdater; - boost::scoped_ptr<ImplScreenUpdater> mpImpl; + std::unique_ptr<ImplScreenUpdater> mpImpl; }; } diff --git a/main/svx/source/sidebar/line/LinePropertyPanel.hxx b/main/svx/source/sidebar/line/LinePropertyPanel.hxx index 57ca1cad06..7191be9712 100644 --- a/main/svx/source/sidebar/line/LinePropertyPanel.hxx +++ b/main/svx/source/sidebar/line/LinePropertyPanel.hxx @@ -29,9 +29,10 @@ #include <sfx2/sidebar/GridLayouter.hxx> #include <vcl/fixed.hxx> #include <vcl/field.hxx> -#include <boost/scoped_ptr.hpp> +#include <memory> #include <boost/scoped_array.hpp> #include <svx/sidebar/ColorPopup.hxx> +#include <memory> #include "LineWidthPopup.hxx" namespace svx { class ToolboxButtonColorUpdater; } @@ -48,8 +49,8 @@ class ListBox; class ToolBox; class FloatingWindow; -typedef ::boost::shared_ptr< XLineEndList > XLineEndListSharedPtr; -typedef ::boost::shared_ptr< XDashList > XDashListSharedPtr; +typedef ::std::shared_ptr< XLineEndList > XLineEndListSharedPtr; +typedef ::std::shared_ptr< XDashList > XDashListSharedPtr; namespace { #define SIDEBAR_LINE_WIDTH_GLOBAL_VALUE String("PopupPanel_LineWidth", 20, RTL_TEXTENCODING_ASCII_US) @@ -97,23 +98,23 @@ public: private: //ui controls - ::boost::scoped_ptr< FixedText > mpFTWidth; - ::boost::scoped_ptr< Window > mpTBWidthBackground; - ::boost::scoped_ptr< ToolBox > mpTBWidth; - ::boost::scoped_ptr< FixedText > mpFTColor; - ::boost::scoped_ptr< Window > mpTBColorBackground; - ::boost::scoped_ptr< ToolBox > mpTBColor; - ::boost::scoped_ptr< FixedText > mpFTStyle; - ::boost::scoped_ptr< ListBox > mpLBStyle; - ::boost::scoped_ptr< FixedText > mpFTTrancparency; - ::boost::scoped_ptr< MetricField > mpMFTransparent; - ::boost::scoped_ptr< FixedText > mpFTArrow; - ::boost::scoped_ptr< ListBox > mpLBStart; - ::boost::scoped_ptr< ListBox > mpLBEnd; - ::boost::scoped_ptr< FixedText > mpFTEdgeStyle; - ::boost::scoped_ptr< ListBox > mpLBEdgeStyle; - ::boost::scoped_ptr< FixedText > mpFTCapStyle; - ::boost::scoped_ptr< ListBox > mpLBCapStyle; + ::std::unique_ptr< FixedText > mpFTWidth; + ::std::unique_ptr< Window > mpTBWidthBackground; + ::std::unique_ptr< ToolBox > mpTBWidth; + ::std::unique_ptr< FixedText > mpFTColor; + ::std::unique_ptr< Window > mpTBColorBackground; + ::std::unique_ptr< ToolBox > mpTBColor; + ::std::unique_ptr< FixedText > mpFTStyle; + ::std::unique_ptr< ListBox > mpLBStyle; + ::std::unique_ptr< FixedText > mpFTTrancparency; + ::std::unique_ptr< MetricField > mpMFTransparent; + ::std::unique_ptr< FixedText > mpFTArrow; + ::std::unique_ptr< ListBox > mpLBStart; + ::std::unique_ptr< ListBox > mpLBEnd; + ::std::unique_ptr< FixedText > mpFTEdgeStyle; + ::std::unique_ptr< ListBox > mpLBEdgeStyle; + ::std::unique_ptr< FixedText > mpFTCapStyle; + ::std::unique_ptr< ListBox > mpLBCapStyle; //ControllerItem ::sfx2::sidebar::ControllerItem maStyleControl; @@ -129,16 +130,16 @@ private: ::sfx2::sidebar::ControllerItem maCapStyle; Color maColor; - ::boost::scoped_ptr< ::svx::ToolboxButtonColorUpdater > mpColorUpdater; - ::boost::scoped_ptr< XLineStyleItem > mpStyleItem; - ::boost::scoped_ptr< XLineDashItem > mpDashItem; + ::std::unique_ptr< ::svx::ToolboxButtonColorUpdater > mpColorUpdater; + ::std::unique_ptr< XLineStyleItem > mpStyleItem; + ::std::unique_ptr< XLineDashItem > mpDashItem; sal_uInt16 mnTrans; SfxMapUnit meMapUnit; sal_Int32 mnWidthCoreValue; XLineEndListSharedPtr maLineEndList; XDashListSharedPtr maLineStyleList; - ::boost::scoped_ptr< XLineStartItem > mpStartItem; - ::boost::scoped_ptr< XLineEndItem > mpEndItem; + ::std::unique_ptr< XLineStartItem > mpStartItem; + ::std::unique_ptr< XLineEndItem > mpEndItem; //popup windows ColorPopup maColorPopup; diff --git a/main/sw/inc/doc.hxx b/main/sw/inc/doc.hxx index 4e4daf3283..a622753643 100644 --- a/main/sw/inc/doc.hxx +++ b/main/sw/inc/doc.hxx @@ -87,8 +87,8 @@ class SwList; #include <map> #include <memory> -#include <boost/scoped_ptr.hpp> -#include <boost/shared_ptr.hpp> +#include <memory> +#include <memory> #include <flypos.hxx> class SvxForbiddenCharactersTable; @@ -283,7 +283,7 @@ class SW_DLLPUBLIC SwDoc : //---------------- private Member -------------------------------- // ------------------------------------------------------------------- - ::boost::scoped_ptr<SwNodes> m_pNodes; /// document content (Nodes Array) + ::std::unique_ptr<SwNodes> m_pNodes; /// document content (Nodes Array) SwAttrPool* mpAttrPool; // der Attribut Pool SwPageDescs aPageDescs; // PageDescriptoren Link aOle2Link; // OLE 2.0-Benachrichtigung @@ -300,9 +300,9 @@ class SW_DLLPUBLIC SwDoc : xXForms; // container with XForms models mutable com::sun::star::uno::Reference< com::sun::star::linguistic2::XProofreadingIterator > m_xGCIterator; - const ::boost::scoped_ptr< ::sw::mark::MarkManager> pMarkManager; - const ::boost::scoped_ptr< ::sw::MetaFieldManager > m_pMetaFieldManager; - const ::boost::scoped_ptr< ::sw::UndoManager > m_pUndoManager; + const ::std::unique_ptr< ::sw::mark::MarkManager> pMarkManager; + const ::std::unique_ptr< ::sw::MetaFieldManager > m_pMetaFieldManager; + const ::std::unique_ptr< ::sw::UndoManager > m_pUndoManager; // ------------------------------------------------------------------- // die Pointer @@ -326,7 +326,7 @@ class SW_DLLPUBLIC SwDoc : SwDefTOXBase_Impl * pDefTOXBases; // defaults of SwTOXBase's ViewShell *pCurrentView; // SwDoc should get a new member pCurrentView//swmod 071225 - boost::shared_ptr<SwRootFrm> pLayoutPtr; + std::shared_ptr<SwRootFrm> pLayoutPtr; SwDrawModel* pDrawModel; // StarView Drawing SwDocUpdtFld *pUpdtFlds; // Struktur zum Field-Update @@ -1839,7 +1839,7 @@ public: const SwDocShell* GetDocShell() const { return pDocShell; } void SetDocShell( SwDocShell* pDSh ); - void ShareLayout( boost::shared_ptr<SwRootFrm>& rPtr); + void ShareLayout( std::shared_ptr<SwRootFrm>& rPtr); // in case during copying of embedded object a new shell is created, // it should be set here and cleaned later diff --git a/main/vcl/source/gdi/image.cxx b/main/vcl/source/gdi/image.cxx index b1c81424ca..5992c1130f 100644 --- a/main/vcl/source/gdi/image.cxx +++ b/main/vcl/source/gdi/image.cxx @@ -22,7 +22,7 @@ // MARKER(update_precomp.py): autogen include statement, do not remove #include "precompiled_vcl.hxx" -#include <boost/scoped_ptr.hpp> +#include <memory> #include <boost/scoped_array.hpp> #include <rtl/logfile.hxx> @@ -440,7 +440,7 @@ ImageList::ImageList( const ResId& rResId ) : sal_uLong nObjMask = pResMgr->ReadLong(); const String aPrefix( pResMgr->ReadString() ); - ::boost::scoped_ptr< Color > spMaskColor; + ::std::unique_ptr< Color > spMaskColor; if( nObjMask & RSC_IMAGE_MASKCOLOR ) spMaskColor.reset( new Color( ResId( (RSHEADER_TYPE*)pResMgr->GetClass(), *pResMgr ) ) ); diff --git a/main/xmloff/source/text/txtimp.cxx b/main/xmloff/source/text/txtimp.cxx index b494e2e487..785c83d40d 100644 --- a/main/xmloff/source/text/txtimp.cxx +++ b/main/xmloff/source/text/txtimp.cxx @@ -27,7 +27,7 @@ #include <vector> #include <boost/scoped_array.hpp> -#include <boost/tuple/tuple.hpp> +#include <tuple> #include <tools/solar.h> #include <tools/debug.hxx> @@ -562,7 +562,7 @@ struct SAL_DLLPRIVATE XMLTextImportHelper::Impl // <-- // start range, xml:id, RDFa stuff - typedef ::boost::tuple< + typedef ::std::tuple< uno::Reference<text::XTextRange>, ::rtl::OUString, ::boost::shared_ptr< ::xmloff::ParsedRDFaAttributes > > BookmarkMapEntry_t; @@ -2724,7 +2724,7 @@ void XMLTextImportHelper::InsertBookmarkStartRange( ::boost::shared_ptr< ::xmloff::ParsedRDFaAttributes > & i_rpRDFaAttributes) { m_pImpl->m_BookmarkStartRanges[sName] = - ::boost::make_tuple(rRange, i_rXmlId, i_rpRDFaAttributes); + ::std::make_tuple(rRange, i_rXmlId, i_rpRDFaAttributes); m_pImpl->m_BookmarkVector.push_back(sName); }
