2
0
Fork 0

Merge pull request #37486 from RandomShaper/fix_trimmed_res

Fix res:// trimmed to s:// on Windows
4.0
Rémi Verschelde 2020-04-01 15:01:31 +07:00 committed by GitHub
commit d229507fa7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 1 deletions

@ -206,7 +206,13 @@ String DirAccessWindows::get_current_dir(bool p_include_drive) {
if (p_include_drive) {
return current_dir;
} else {
return current_dir.right(current_dir.find(":") + 1);
if (_get_root_string() == "") {
int p = current_dir.find(":");
if (p != -1) {
return current_dir.right(p + 1);
}
}
return current_dir;
}
}