mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-07-10 04:46:48 -04:00
Dusklight mod API core
Co-authored-by: qwertyquerty <qwertytrogi@gmail.com> Co-authored-by: PJB3005 <pieterjan.briers+git@gmail.com>
This commit is contained in:
+8
-8
@@ -121,14 +121,6 @@ std::filesystem::path active_pref_path() {
|
||||
return get_pref_path();
|
||||
}
|
||||
|
||||
std::filesystem::path base_path_relative(const std::filesystem::path& path) {
|
||||
const auto* basePath = SDL_GetBasePath();
|
||||
if (!basePath) {
|
||||
return path;
|
||||
}
|
||||
return path_from_utf8(basePath) / path;
|
||||
}
|
||||
|
||||
std::filesystem::path default_data_path(const std::filesystem::path& prefPath) {
|
||||
#ifdef __APPLE__
|
||||
#if TARGET_OS_IOS && !TARGET_OS_TV
|
||||
@@ -888,6 +880,14 @@ void ensure_data_directory(const std::filesystem::path& dataPath) {
|
||||
|
||||
} // namespace
|
||||
|
||||
std::filesystem::path base_path_relative(const std::filesystem::path& path) {
|
||||
const auto* basePath = SDL_GetBasePath();
|
||||
if (!basePath) {
|
||||
return path;
|
||||
}
|
||||
return path_from_utf8(basePath) / path;
|
||||
}
|
||||
|
||||
bool open_data_path() {
|
||||
#if DUSK_CAN_OPEN_DATA_FOLDER
|
||||
std::error_code ec;
|
||||
|
||||
Reference in New Issue
Block a user