Added a workaround to avoid crashes due to how TileSet editor works, fixes #23672

Also fixed a few uninitialized memory variables.
This commit is contained in:
Juan Linietsky
2019-02-22 17:42:29 -03:00
parent 16e67388a2
commit 7f63b0e8cd
6 changed files with 10 additions and 1 deletions

View File

@@ -2439,7 +2439,7 @@ void EditorPropertyResource::_button_input(const Ref<InputEvent> &p_event) {
void EditorPropertyResource::_open_editor_pressed() {
RES res = get_edited_object()->get(get_edited_property());
if (res.is_valid()) {
EditorNode::get_singleton()->edit_item(res.ptr());
EditorNode::get_singleton()->call_deferred("edit_item_resource", res); //may clear the editor so do it deferred
}
}