[PT Run] Closing PT Run and new settings app when PowerToys is not running (#3853)

Closing PowerLauncher, FZ Editor and new settings app when PowerToys is not running
This commit is contained in:
Yevhenii Holovachov
2020-06-10 20:58:34 +03:00
committed by GitHub
parent 38350a1ae4
commit 6fdfd3b9e7
7 changed files with 111 additions and 6 deletions

View File

@@ -192,6 +192,7 @@ int WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
std::wstring_view target;
std::wstring_view pidFile;
std::wstring params;
while (nextArg < nArgs)
{
@@ -207,6 +208,7 @@ int WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
}
else
{
params = args[nextArg];
nextArg++;
}
}
@@ -227,7 +229,7 @@ int WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
}
}
run_same_elevation(target.data(), L"", pidBuffer);
run_same_elevation(target.data(), params, pidBuffer);
// cleanup
if (!pidFile.empty())