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/EditView.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/EditView.cxx') diff --git a/src/EditView.cxx b/src/EditView.cxx index 1c6e41096..1ec163d27 100644 --- a/src/EditView.cxx +++ b/src/EditView.cxx @@ -268,11 +268,11 @@ void EditView::DropGraphics(bool freeObjects) { void EditView::AllocateGraphics(const ViewStyle &vsDraw) { if (!pixmapLine) - pixmapLine.reset(Surface::Allocate(vsDraw.technology)); + pixmapLine = Surface::Allocate(vsDraw.technology); if (!pixmapIndentGuide) - pixmapIndentGuide.reset(Surface::Allocate(vsDraw.technology)); + pixmapIndentGuide = Surface::Allocate(vsDraw.technology); if (!pixmapIndentGuideHighlight) - pixmapIndentGuideHighlight.reset(Surface::Allocate(vsDraw.technology)); + pixmapIndentGuideHighlight = Surface::Allocate(vsDraw.technology); } static const char *ControlCharacterString(unsigned char ch) noexcept { -- cgit v1.2.3