mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
Improve to_string() and add it to Resource
This commit is contained in:
parent
9a5d6d1049
commit
e6783dbdd1
13 changed files with 53 additions and 61 deletions
|
|
@ -660,6 +660,10 @@ void Resource::reset_local_to_scene() {
|
|||
// Restores the state as if setup_local_to_scene() hadn't been called.
|
||||
}
|
||||
|
||||
String Resource::_to_string() {
|
||||
return (name.is_empty() ? "" : String(name) + " ") + "(" + path_cache + "):" + Object::_to_string();
|
||||
}
|
||||
|
||||
Node *(*Resource::_get_local_scene_func)() = nullptr;
|
||||
void (*Resource::_update_configuration_warning)() = nullptr;
|
||||
|
||||
|
|
|
|||
|
|
@ -122,6 +122,7 @@ protected:
|
|||
GDVIRTUAL0(_reset_state);
|
||||
|
||||
virtual Ref<Resource> _duplicate(const DuplicateParams &p_params) const;
|
||||
virtual String _to_string() override;
|
||||
|
||||
public:
|
||||
static Node *(*_get_local_scene_func)(); // Used by the editor.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue