mirror of
https://github.com/godotengine/godot.git
synced 2025-11-01 14:11:15 +00:00
Relaxes Node naming constraints in glTF documents to match the Editor.
This commit is contained in:
parent
db246f8edb
commit
b032067e42
9 changed files with 72 additions and 35 deletions
|
|
@ -785,10 +785,10 @@ void SceneTreeEditor::_renamed() {
|
|||
return;
|
||||
}
|
||||
|
||||
String new_name = which->get_text(0);
|
||||
if (!Node::_validate_node_name(new_name)) {
|
||||
|
||||
error->set_text(TTR("Invalid node name, the following characters are not allowed:") + "\n" + Node::invalid_character);
|
||||
String raw_new_name = which->get_text(0);
|
||||
String new_name = raw_new_name.validate_node_name();
|
||||
if (new_name != raw_new_name) {
|
||||
error->set_text(TTR("Invalid node name, the following characters are not allowed:") + "\n" + String::invalid_node_name_characters);
|
||||
error->popup_centered_minsize();
|
||||
|
||||
if (new_name.empty()) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue