Update NodePaths only in built-in resources
This commit is contained in:
parent
f040a351c2
commit
77879d4288
1 changed files with 6 additions and 5 deletions
|
@ -1812,8 +1812,6 @@ bool SceneTreeDock::_check_node_path_recursive(Node *p_root_node, Variant &r_var
|
||||||
}
|
}
|
||||||
} break;
|
} break;
|
||||||
|
|
||||||
// FIXME: This approach causes a significant performance regression, see GH-84910.
|
|
||||||
#if 0
|
|
||||||
case Variant::OBJECT: {
|
case Variant::OBJECT: {
|
||||||
Resource *resource = Object::cast_to<Resource>(r_variant);
|
Resource *resource = Object::cast_to<Resource>(r_variant);
|
||||||
if (!resource) {
|
if (!resource) {
|
||||||
|
@ -1825,6 +1823,11 @@ bool SceneTreeDock::_check_node_path_recursive(Node *p_root_node, Variant &r_var
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!resource->is_built_in()) {
|
||||||
|
// For performance reasons, assume that scene paths are no concern for external resources.
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
List<PropertyInfo> properties;
|
List<PropertyInfo> properties;
|
||||||
resource->get_property_list(&properties);
|
resource->get_property_list(&properties);
|
||||||
|
|
||||||
|
@ -1841,9 +1844,7 @@ bool SceneTreeDock::_check_node_path_recursive(Node *p_root_node, Variant &r_var
|
||||||
undo_redo->add_undo_property(resource, propertyname, old_variant);
|
undo_redo->add_undo_property(resource, propertyname, old_variant);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
} break;
|
||||||
};
|
|
||||||
#endif
|
|
||||||
|
|
||||||
default: {
|
default: {
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue