Skip to content

Commit edf17d6

Browse files
committed
Merge branch 'fix-TTR-resource-picker' of github.com:MattiaZir/godot into fix-TTR-resource-picker
# Conflicts: # editor/inspector/editor_resource_picker.cpp
2 parents 925baf1 + 1311ef6 commit edf17d6

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

editor/inspector/editor_resource_picker.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ void EditorResourcePicker::_update_resource() {
113113
resource_name = edited_resource->get_class();
114114

115115
if (edited_resource->has_meta(SceneStringNames::get_singleton()->_custom_type_script)) {
116-
if (const Ref<Script> custom_script = PropertyUtils::get_custom_type_script(*edited_resource); custom_script.is_valid()) {
116+
if (const Ref<Script> custom_script = PropertyUtils::get_custom_type_script(edited_resource.ptr()); custom_script.is_valid()) {
117117
if (const String global_name = custom_script->get_global_name(); !global_name.is_empty()) {
118118
resource_name = global_name;
119119
}
@@ -122,20 +122,20 @@ void EditorResourcePicker::_update_resource() {
122122
}
123123

124124
if (num_of_copies > 1) {
125-
tooltip = vformat(TTRN("This %s is used in %d place.", "This %s is used in %d places.", num_of_copies), resource_name, num_of_copies);
125+
tooltip = vformat(TTR("This Resource is used in (%d) places."), num_of_copies);
126126
} else if (!is_internal) {
127-
tooltip = vformat(TTR("This %s is external to scene."), resource_name);
127+
tooltip = TTR("This Resource is external to scene.");
128128
}
129129

130130
if (!editable) {
131-
tooltip += "\n" + vformat(TTR("The %s cannot be edited in the inspector and can't be made unique directly."), resource_name) + "\n";
131+
tooltip += "\n" + TTR("The Resource cannot be edited in the inspector and can't be made unique directly.") + "\n";
132132
} else {
133133
if (unique_enable) {
134-
tooltip += "\n" + TTR("Left-click to make it unique.") + "\n";
134+
tooltip += "\n" + TTR("Left-click to make it unique.") + "\n";
135135
}
136136

137137
if (unique_recursive_enabled) {
138-
tooltip += TTR("It is possible to make its subresources unique.") + "\n" + TTR("Right-click to make them unique.");
138+
tooltip += TTR("It is possible to make its subresources unique. Right-click to make them unique.") + "\n";
139139
}
140140

141141
if (!unique_enable && EditorNode::get_singleton()->get_editor_selection()->get_full_selected_node_list().size() == 1) {

0 commit comments

Comments
 (0)