From a5547ac3c76dde1c42c8edb7d56b77f93b313197 Mon Sep 17 00:00:00 2001 From: Cameron Reikes Date: Thu, 8 Aug 2019 19:34:23 -0700 Subject: [PATCH] Button object used after pressed is called - by queueing for deletion node can call own cleanup methods (cherry picked from commit c69ff6833c4bd6b42b9cad70928544fc6b7cbfc4) --- editor/editor_properties_array_dict.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/editor/editor_properties_array_dict.cpp b/editor/editor_properties_array_dict.cpp index 0f6c6349ed7..ceb045f4fb1 100644 --- a/editor/editor_properties_array_dict.cpp +++ b/editor/editor_properties_array_dict.cpp @@ -306,7 +306,8 @@ void EditorPropertyArray::update_property() { } else { //bye bye children of the box while (vbox->get_child_count() > 2) { - memdelete(vbox->get_child(2)); + vbox->get_child(2)->queue_delete(); // button still needed after pressed is called + vbox->remove_child(vbox->get_child(2)); } }