Style: Replaces uses of 0/NULL by nullptr (C++11)
Using clang-tidy's `modernize-use-nullptr`. https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-nullptr.html
This commit is contained in:
@ -40,7 +40,7 @@
|
||||
|
||||
static Node *_find_first_script(Node *p_root, Node *p_node) {
|
||||
if (p_node != p_root && p_node->get_owner() != p_root) {
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
if (!p_node->get_script().is_null()) {
|
||||
return p_node;
|
||||
@ -53,7 +53,7 @@ static Node *_find_first_script(Node *p_root, Node *p_node) {
|
||||
}
|
||||
}
|
||||
|
||||
return NULL;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
class ConnectDialogBinds : public Object {
|
||||
@ -321,7 +321,7 @@ void ConnectDialog::init(Connection c, bool bEdit) {
|
||||
source = static_cast<Node *>(c.source);
|
||||
signal = c.signal;
|
||||
|
||||
tree->set_selected(NULL);
|
||||
tree->set_selected(nullptr);
|
||||
tree->set_marked(source, true);
|
||||
|
||||
if (c.target) {
|
||||
@ -574,7 +574,7 @@ void ConnectionsDock::_make_or_edit_connection() {
|
||||
}
|
||||
|
||||
// IMPORTANT NOTE: _disconnect and _connect cause an update_tree, which will delete the object "it" is pointing to.
|
||||
it = NULL;
|
||||
it = nullptr;
|
||||
|
||||
if (add_script_function) {
|
||||
editor->emit_signal("script_add_function_request", target, cToMake.method, script_function_args);
|
||||
@ -910,7 +910,7 @@ void ConnectionsDock::update_tree() {
|
||||
icon = get_icon("Object", "EditorIcons");
|
||||
}
|
||||
|
||||
TreeItem *section_item = NULL;
|
||||
TreeItem *section_item = nullptr;
|
||||
|
||||
// Create subsections.
|
||||
if (node_signals2.size()) {
|
||||
|
||||
Reference in New Issue
Block a user