diff options
-rw-r--r-- | editor/editor_node.cpp | 2 | ||||
-rw-r--r-- | editor/import_dock.cpp | 8 | ||||
-rw-r--r-- | editor/import_dock.h | 1 |
3 files changed, 10 insertions, 1 deletions
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 90e9e2551a..ce55438de4 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -6210,6 +6210,8 @@ EditorNode::EditorNode() { editor_data.set_edited_scene(0); _update_scene_tabs(); + import_dock->initialize_import_options(); + { _initializing_addons = true; diff --git a/editor/import_dock.cpp b/editor/import_dock.cpp index 24647734ce..dff36ae742 100644 --- a/editor/import_dock.cpp +++ b/editor/import_dock.cpp @@ -309,6 +309,13 @@ void ImportDock::_bind_methods() { ClassDB::bind_method(D_METHOD("_preset_selected"), &ImportDock::_preset_selected); } +void ImportDock::initialize_import_options() const { + + ERR_FAIL_COND(!import_opts || !params); + + import_opts->edit(params); +} + ImportDock::ImportDock() { imported = memnew(LineEdit); @@ -339,7 +346,6 @@ ImportDock::ImportDock() { hb->add_spacer(); params = memnew(ImportDockParameters); - import_opts->edit(params); } ImportDock::~ImportDock() { diff --git a/editor/import_dock.h b/editor/import_dock.h index fc99fcc586..171aabe407 100644 --- a/editor/import_dock.h +++ b/editor/import_dock.h @@ -63,6 +63,7 @@ protected: public: void set_edit_path(const String &p_path); void set_edit_multiple_paths(const Vector<String> &p_paths); + void initialize_import_options() const; void clear(); ImportDock(); |