From f4349fb3e45bd44cef0e2b69af4c9b4cf35dcf43 Mon Sep 17 00:00:00 2001 From: Emmanuel Gil Peyrot Date: Fri, 15 Jun 2018 12:46:15 +0200 Subject: =?UTF-8?q?Run=20clang-tidy=E2=80=99s=20modernize-use-nullptr=20pa?= =?UTF-8?q?ss.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This replaces all NULL or 0 with nullptr when assigned to or returned as a pointer. --- src/display/drawing-pattern.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/display/drawing-pattern.cpp') diff --git a/src/display/drawing-pattern.cpp b/src/display/drawing-pattern.cpp index b590a59c5..2cb86440e 100644 --- a/src/display/drawing-pattern.cpp +++ b/src/display/drawing-pattern.cpp @@ -18,7 +18,7 @@ namespace Inkscape { DrawingPattern::DrawingPattern(Drawing &drawing, bool debug) : DrawingGroup(drawing) - , _pattern_to_user(NULL) + , _pattern_to_user(nullptr) , _overflow_steps(1) , _debug(debug) { @@ -41,7 +41,7 @@ DrawingPattern::setPatternToUserTransform(Geom::Affine const &new_trans) { _markForRendering(); if (new_trans.isIdentity()) { delete _pattern_to_user; // delete NULL; is safe - _pattern_to_user = NULL; + _pattern_to_user = nullptr; } else { _pattern_to_user = new Geom::Affine(new_trans); } @@ -67,11 +67,11 @@ DrawingPattern::renderPattern(float opacity) { bool visible = opacity >= 1e-3; if (!visible) { - return NULL; + return nullptr; } if (!_tile_rect || (_tile_rect->area() == 0)) { - return NULL; + return nullptr; } Geom::Rect pattern_tile = *_tile_rect; -- cgit v1.2.3