summaryrefslogtreecommitdiffstats
path: root/editor/editor_node.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/editor_node.cpp')
-rw-r--r--editor/editor_node.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp
index b9ac7b6d42..5bb9aa91d2 100644
--- a/editor/editor_node.cpp
+++ b/editor/editor_node.cpp
@@ -3486,6 +3486,10 @@ void EditorNode::remove_editor_plugin(EditorPlugin *p_editor, bool p_config_chan
}
}
+ if (singleton->editor_plugin_screen == p_editor) {
+ singleton->editor_plugin_screen = nullptr;
+ }
+
singleton->editor_table.erase(p_editor);
}
p_editor->make_visible(false);
@@ -3512,6 +3516,7 @@ void EditorNode::add_extension_editor_plugin(const StringName &p_class_name) {
EditorPlugin *plugin = Object::cast_to<EditorPlugin>(ClassDB::instantiate(p_class_name));
singleton->editor_data.add_extension_editor_plugin(p_class_name, plugin);
add_editor_plugin(plugin);
+ plugin->enable_plugin();
}
void EditorNode::remove_extension_editor_plugin(const StringName &p_class_name) {
@@ -7255,7 +7260,9 @@ EditorNode::EditorNode() {
add_editor_plugin(memnew(AudioBusesEditorPlugin(audio_bus_editor)));
for (int i = 0; i < EditorPlugins::get_plugin_count(); i++) {
- add_editor_plugin(EditorPlugins::create(i));
+ EditorPlugin *plugin = EditorPlugins::create(i);
+ add_editor_plugin(plugin);
+ plugin->enable_plugin();
}
for (const StringName &extension_class_name : GDExtensionEditorPlugins::get_extension_classes()) {