mirror of
https://github.com/godotengine/godot.git
synced 2025-01-10 03:51:21 +00:00
Suppress get_edited_scene_root error
This commit is contained in:
parent
38c471bef6
commit
a572eb6453
@ -6210,6 +6210,8 @@ EditorNode::EditorNode() {
|
||||
editor_data.set_edited_scene(0);
|
||||
_update_scene_tabs();
|
||||
|
||||
import_dock->initialize_import_options();
|
||||
|
||||
{
|
||||
|
||||
_initializing_addons = true;
|
||||
|
@ -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() {
|
||||
|
@ -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();
|
||||
|
Loading…
Reference in New Issue
Block a user