summaryrefslogtreecommitdiffstats
path: root/scene/gui/label.cpp
diff options
context:
space:
mode:
authorlupoDharkael <izhe@hotmail.es>2020-04-02 01:20:12 +0200
committerlupoDharkael <izhe@hotmail.es>2020-04-02 13:38:00 +0200
commit95a1400a2ac9de1a29fa305f45b928ce8e3044bd (patch)
treebe0cd59e5a90926e9d653fed9f3b1b77e735ca2f /scene/gui/label.cpp
parent5f11e1557156617366d2c316a97716172103980d (diff)
downloadredot-engine-95a1400a2ac9de1a29fa305f45b928ce8e3044bd.tar.gz
Replace NULL with nullptr
Diffstat (limited to 'scene/gui/label.cpp')
-rw-r--r--scene/gui/label.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/scene/gui/label.cpp b/scene/gui/label.cpp
index 1ffc9712cc..bedcef2df2 100644
--- a/scene/gui/label.cpp
+++ b/scene/gui/label.cpp
@@ -282,7 +282,7 @@ void Label::_notification(int p_what) {
from = from->next;
}
- wc = to ? to->next : 0;
+ wc = to ? to->next : nullptr;
line++;
}
}
@@ -404,7 +404,7 @@ void Label::regenerate_word_cache() {
line_count = 1;
total_char_cache = 0;
- WordCache *last = NULL;
+ WordCache *last = nullptr;
for (int i = 0; i <= xl_text.length(); i++) {
@@ -447,7 +447,7 @@ void Label::regenerate_word_cache() {
}
if (i < xl_text.length() && xl_text[i] == ' ') {
- if (line_width > 0 || last == NULL || last->char_pos != WordCache::CHAR_WRAPLINE) {
+ if (line_width > 0 || last == nullptr || last->char_pos != WordCache::CHAR_WRAPLINE) {
space_count++;
line_width += space_width;
} else {
@@ -697,7 +697,7 @@ Label::Label(const String &p_text) {
align = ALIGN_LEFT;
valign = VALIGN_TOP;
xl_text = "";
- word_cache = NULL;
+ word_cache = nullptr;
word_cache_dirty = true;
autowrap = false;
line_count = 0;