From 8c9d9eb84cd613c921ed860d7fecded070446d6d Mon Sep 17 00:00:00 2001 From: David Capello Date: Thu, 3 Mar 2016 19:20:57 -0300 Subject: [PATCH] Replace NULL with nullptr on files that don't include base/base.h --- src/base/connection.h | 6 +++--- src/doc/site.h | 10 +++++----- src/ui/cursor.cpp | 2 +- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/base/connection.h b/src/base/connection.h index 14f29918e..180725b22 100644 --- a/src/base/connection.h +++ b/src/base/connection.h @@ -1,5 +1,5 @@ // Aseprite Base Library -// Copyright (c) 2001-2015 David Capello +// Copyright (c) 2001-2016 David Capello // // This file is released under the terms of the MIT license. // Read LICENSE.txt for more information. @@ -15,7 +15,7 @@ class Slot; class Connection { public: - Connection() : m_signal(NULL), m_slot(NULL) { + Connection() : m_signal(nullptr), m_slot(nullptr) { } Connection(Signal* signal, Slot* slot) : @@ -25,7 +25,7 @@ public: void disconnect(); operator bool() { - return (m_slot != NULL); + return (m_slot != nullptr); } private: diff --git a/src/doc/site.h b/src/doc/site.h index e459befac..d1b051944 100644 --- a/src/doc/site.h +++ b/src/doc/site.h @@ -1,5 +1,5 @@ // Aseprite Document Library -// Copyright (c) 2001-2015 David Capello +// Copyright (c) 2001-2016 David Capello // // This file is released under the terms of the MIT license. // Read LICENSE.txt for more information. @@ -26,9 +26,9 @@ namespace doc { class Site { public: Site() - : m_document(NULL) - , m_sprite(NULL) - , m_layer(NULL) + : m_document(nullptr) + , m_sprite(nullptr) + , m_layer(nullptr) , m_frame(0) { } const Document* document() const { return m_document; } @@ -50,7 +50,7 @@ namespace doc { LayerIndex layerIndex() const; void layerIndex(LayerIndex layerIndex); Palette* palette(); - Image* image(int* x = NULL, int* y = NULL, int* opacity = NULL) const; + Image* image(int* x = nullptr, int* y = nullptr, int* opacity = nullptr) const; Palette* palette() const; private: diff --git a/src/ui/cursor.cpp b/src/ui/cursor.cpp index 67cad3ac4..44a09e22f 100644 --- a/src/ui/cursor.cpp +++ b/src/ui/cursor.cpp @@ -19,7 +19,7 @@ Cursor::Cursor(she::Surface* surface, const gfx::Point& focus) : m_surface(surface) , m_focus(focus) { - ASSERT(m_surface != NULL); + ASSERT(m_surface != nullptr); } Cursor::~Cursor()