From 10a56981dc7bf2d0f0decd56a005ea1c2986e279 Mon Sep 17 00:00:00 2001 From: Aaron Franke Date: Mon, 29 Aug 2022 19:34:01 -0500 Subject: Rename String `plus_file` to `path_join` --- scene/resources/font.cpp | 4 ++-- scene/resources/resource_format_text.cpp | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'scene/resources') diff --git a/scene/resources/font.cpp b/scene/resources/font.cpp index 8ec5678f0a..189d8d5502 100644 --- a/scene/resources/font.cpp +++ b/scene/resources/font.cpp @@ -1427,7 +1427,7 @@ Error FontFile::load_bitmap_font(const String &p_path) { while (!f->eof_reached() && f->get_position() <= off + block_size) { if (c == '\0') { String base_dir = p_path.get_base_dir(); - String file = base_dir.plus_file(String::utf8(cs.ptr(), cs.length())); + String file = base_dir.path_join(String::utf8(cs.ptr(), cs.length())); if (RenderingServer::get_singleton() != nullptr) { Ref img; img.instantiate(); @@ -1660,7 +1660,7 @@ Error FontFile::load_bitmap_font(const String &p_path) { } if (keys.has("file")) { String base_dir = p_path.get_base_dir(); - String file = base_dir.plus_file(keys["file"]); + String file = base_dir.path_join(keys["file"]); if (RenderingServer::get_singleton() != nullptr) { Ref img; img.instantiate(); diff --git a/scene/resources/resource_format_text.cpp b/scene/resources/resource_format_text.cpp index 2b1d91e4ef..0d798d2e27 100644 --- a/scene/resources/resource_format_text.cpp +++ b/scene/resources/resource_format_text.cpp @@ -451,7 +451,7 @@ Error ResourceLoaderText::load() { if (!path.contains("://") && path.is_relative_path()) { // path is relative to file being loaded, so convert to a resource path - path = ProjectSettings::get_singleton()->localize_path(local_path.get_base_dir().plus_file(path)); + path = ProjectSettings::get_singleton()->localize_path(local_path.get_base_dir().path_join(path)); } if (remaps.has(path)) { @@ -861,7 +861,7 @@ void ResourceLoaderText::get_dependencies(Ref p_f, List *p_d if (!using_uid && !path.contains("://") && path.is_relative_path()) { // path is relative to file being loaded, so convert to a resource path - path = ProjectSettings::get_singleton()->localize_path(local_path.get_base_dir().plus_file(path)); + path = ProjectSettings::get_singleton()->localize_path(local_path.get_base_dir().path_join(path)); } if (p_add_types) { @@ -938,7 +938,7 @@ Error ResourceLoaderText::rename_dependencies(Ref p_f, const String } bool relative = false; if (!path.begins_with("res://")) { - path = base_path.plus_file(path).simplify_path(); + path = base_path.path_join(path).simplify_path(); relative = true; } -- cgit v1.2.3