[TASKMGR] Process page: Allow using "Open File Location" functionality without running Explorer shell

If Explorer shell is not available, use ReactOS's alternative file browser instead.
This commit is contained in:
Thamatip Chitpong 2024-04-22 21:04:23 +07:00
parent 6d16d27462
commit cd0bb1af07

View file

@ -1248,8 +1248,11 @@ void ProcessPage_OnOpenFileLocation(void)
StringCchPrintfW(pszCmdLine, dwLength, szCmdFormat, pszExePath); StringCchPrintfW(pszCmdLine, dwLength, szCmdFormat, pszExePath);
/* Call the shell to open the file location and select it */ /* Call the shell to open the file location and select it. If Explorer shell
ShellExecuteW(NULL, L"open", L"explorer.exe", pszCmdLine, NULL, SW_SHOWNORMAL); * is not available, use ReactOS's alternative file browser instead. */
ShellExecuteW(NULL, L"open",
GetShellWindow() ? L"explorer.exe" : L"filebrowser.exe",
pszCmdLine, NULL, SW_SHOWNORMAL);
Cleanup: Cleanup:
HeapFree(GetProcessHeap(), 0, pszCmdLine); HeapFree(GetProcessHeap(), 0, pszCmdLine);