From 402e089842d5aa2bb3774a665e26c42dc91fa5b4 Mon Sep 17 00:00:00 2001 From: Neil Date: Thu, 18 Mar 2021 19:39:42 +1100 Subject: Use unique_ptr for Surface::Allocate to show transfer of ownership. --- src/MarginView.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/MarginView.cxx') diff --git a/src/MarginView.cxx b/src/MarginView.cxx index c7da7e667..555720536 100644 --- a/src/MarginView.cxx +++ b/src/MarginView.cxx @@ -126,11 +126,11 @@ void MarginView::DropGraphics(bool freeObjects) { void MarginView::AllocateGraphics(const ViewStyle &vsDraw) { if (!pixmapSelMargin) - pixmapSelMargin.reset(Surface::Allocate(vsDraw.technology)); + pixmapSelMargin = Surface::Allocate(vsDraw.technology); if (!pixmapSelPattern) - pixmapSelPattern.reset(Surface::Allocate(vsDraw.technology)); + pixmapSelPattern = Surface::Allocate(vsDraw.technology); if (!pixmapSelPatternOffset1) - pixmapSelPatternOffset1.reset(Surface::Allocate(vsDraw.technology)); + pixmapSelPatternOffset1 = Surface::Allocate(vsDraw.technology); } void MarginView::RefreshPixMaps(Surface *surfaceWindow, WindowID wid, const ViewStyle &vsDraw) { -- cgit v1.2.3