Merge pull request #63344 from alfredbaudisch/feature-select-node-toggle-inspector-only
This commit is contained in:
commit
1d9e1ac143
2 changed files with 5 additions and 0 deletions
|
|
@ -2181,6 +2181,7 @@ void EditorNode::_edit_current(bool p_skip_foreign) {
|
|||
Object *prev_inspected_object = InspectorDock::get_inspector_singleton()->get_edited_object();
|
||||
|
||||
bool disable_folding = bool(EDITOR_GET("interface/inspector/disable_folding"));
|
||||
bool stay_in_script_editor_on_node_selected = bool(EDITOR_GET("text_editor/behavior/navigation/stay_in_script_editor_on_node_selected"));
|
||||
bool is_resource = current_obj->is_class("Resource");
|
||||
bool is_node = current_obj->is_class("Node");
|
||||
|
||||
|
|
@ -2219,6 +2220,9 @@ void EditorNode::_edit_current(bool p_skip_foreign) {
|
|||
NodeDock::get_singleton()->set_node(current_node);
|
||||
SceneTreeDock::get_singleton()->set_selected(current_node);
|
||||
InspectorDock::get_singleton()->update(current_node);
|
||||
if (!inspector_only) {
|
||||
inspector_only = stay_in_script_editor_on_node_selected && ScriptEditor::get_singleton()->is_visible_in_tree();
|
||||
}
|
||||
} else {
|
||||
NodeDock::get_singleton()->set_node(nullptr);
|
||||
SceneTreeDock::get_singleton()->set_selected(nullptr);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue