diff options
| author | George Marques | 2016-09-21 19:17:55 -0300 |
|---|---|---|
| committer | Rémi Verschelde | 2016-10-09 17:20:38 +0200 |
| commit | 63b5a80088e9914836f401331aa7549ef78af484 (patch) | |
| tree | fb324231151b4f601b4197cb67a9771b619af7c7 /tools/editor/editor_node.cpp | |
| parent | 45a5769162ddcc936c221d865e1e8b244928ae69 (diff) | |
| download | godot-63b5a80088e9914836f401331aa7549ef78af484.tar.gz godot-63b5a80088e9914836f401331aa7549ef78af484.tar.zst godot-63b5a80088e9914836f401331aa7549ef78af484.zip | |
Fix crash when disabling main screen plugin
(cherry picked from commit 0ec2b7baea235c3c5cf43ab296b40c06982b32de)
Diffstat (limited to '')
| -rw-r--r-- | tools/editor/editor_node.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/editor/editor_node.cpp b/tools/editor/editor_node.cpp index 51df4b58a..6039f67f1 100644 --- a/tools/editor/editor_node.cpp +++ b/tools/editor/editor_node.cpp @@ -3015,6 +3015,10 @@ void EditorNode::remove_editor_plugin(EditorPlugin *p_editor) { if (p_editor->get_name()==singleton->main_editor_buttons[i]->get_text()) { + if (singleton->main_editor_buttons[i]->is_pressed()) { + singleton->_editor_select(EDITOR_SCRIPT); + } + memdelete( singleton->main_editor_buttons[i] ); singleton->main_editor_buttons.remove(i); |
