Update to the latest Platform::CreateProcess

This commit is contained in:
Wojtek Figat
2023-03-22 14:18:52 +01:00
parent c31e4023c4
commit 7d4bf8356e
11 changed files with 103 additions and 32 deletions

View File

@@ -697,9 +697,16 @@ namespace FlaxEditor
// Invoke new instance if need to open a project
if (!string.IsNullOrEmpty(_projectToOpen))
{
string args = string.Format("-project \"{0}\"", _projectToOpen);
var procSettings = new CreateProcessSettings
{
FileName = Platform.ExecutableFilePath,
Arguments = string.Format("-project \"{0}\"", _projectToOpen),
ShellExecute = true,
WaitForEnd = false,
HiddenWindow = false,
};
_projectToOpen = null;
Platform.StartProcess(Platform.ExecutableFilePath, args, null);
Platform.CreateProcess(ref procSettings);
}
}