mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 14:51:51 +00:00
- encapsulate folder/file names in quotes on Windows too
This commit is contained in:
parent
259a8e0f74
commit
dd07f6513f
1 changed files with 2 additions and 1 deletions
|
@ -965,6 +965,7 @@ void I_OpenShellFolder(const char* folder)
|
||||||
FString proc = folder;
|
FString proc = folder;
|
||||||
proc.ReplaceChars('/', '\\');
|
proc.ReplaceChars('/', '\\');
|
||||||
Printf("Opening folder: %s\n", proc.GetChars());
|
Printf("Opening folder: %s\n", proc.GetChars());
|
||||||
|
proc.Format("\"%s\"", proc.GetChars());
|
||||||
ShellExecuteW(NULL, L"open", L"explorer.exe", proc.WideString().c_str(), NULL, SW_SHOWNORMAL);
|
ShellExecuteW(NULL, L"open", L"explorer.exe", proc.WideString().c_str(), NULL, SW_SHOWNORMAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -973,7 +974,7 @@ void I_OpenShellFile(const char* file)
|
||||||
FString proc = file;
|
FString proc = file;
|
||||||
proc.ReplaceChars('/', '\\');
|
proc.ReplaceChars('/', '\\');
|
||||||
Printf("Opening folder to file: %s\n", proc.GetChars());
|
Printf("Opening folder to file: %s\n", proc.GetChars());
|
||||||
proc.Format("/select,%s", proc.GetChars());
|
proc.Format("/select,\"%s\"", proc.GetChars());
|
||||||
ShellExecuteW(NULL, L"open", L"explorer.exe", proc.WideString().c_str(), NULL, SW_SHOWNORMAL);
|
ShellExecuteW(NULL, L"open", L"explorer.exe", proc.WideString().c_str(), NULL, SW_SHOWNORMAL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue