mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-11-23 01:39:17 +01:00
Remove unnecessary async call. Run in different thread
This commit is contained in:
parent
b3f10e1783
commit
3e217266c5
@ -414,7 +414,7 @@ namespace DS4Windows
|
||||
}
|
||||
}
|
||||
|
||||
UpdateTheUpdater();
|
||||
System.Threading.Tasks.Task.Run(() => { UpdateTheUpdater(); });
|
||||
|
||||
this.StartWindowsCheckBox.CheckedChanged += new EventHandler(this.StartWindowsCheckBox_CheckedChanged);
|
||||
new ToolTip().SetToolTip(StartWindowsCheckBox, Properties.Resources.RunAtStartup);
|
||||
@ -484,14 +484,14 @@ namespace DS4Windows
|
||||
tLPControllers.Visible = !nocontrollers;
|
||||
}
|
||||
|
||||
private async void UpdateTheUpdater()
|
||||
private void UpdateTheUpdater()
|
||||
{
|
||||
if (File.Exists(exepath + "\\Update Files\\DS4Updater.exe"))
|
||||
{
|
||||
Process[] processes = Process.GetProcessesByName("DS4Updater");
|
||||
while (processes.Length > 0)
|
||||
{
|
||||
await System.Threading.Tasks.Task.Delay(500);
|
||||
System.Threading.Thread.Sleep(500);
|
||||
}
|
||||
|
||||
File.Delete(exepath + "\\DS4Updater.exe");
|
||||
|
Loading…
Reference in New Issue
Block a user