mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-11-23 01:39:17 +01:00
Added minor check if timer needs to be run
This commit is contained in:
parent
cde7d19c80
commit
34d2d74415
@ -87,18 +87,27 @@ namespace DS4WinWPF.DS4Forms
|
|||||||
{
|
{
|
||||||
File.Move(tempInstFileName, filename);
|
File.Move(tempInstFileName, filename);
|
||||||
}
|
}
|
||||||
|
success = false; // Reset for later check
|
||||||
|
|
||||||
if (File.Exists(DS4Windows.Global.exedirpath + $"\\{InstFileName}"))
|
if (File.Exists(DS4Windows.Global.exedirpath + $"\\{InstFileName}"))
|
||||||
{
|
{
|
||||||
//vigemInstallBtn.Content = Properties.Resources.OpeningInstaller;
|
//vigemInstallBtn.Content = Properties.Resources.OpeningInstaller;
|
||||||
monitorProc = Process.Start(DS4Windows.Global.exedirpath + $"\\{InstFileName}");
|
monitorProc = Process.Start(DS4Windows.Global.exedirpath + $"\\{InstFileName}");
|
||||||
vigemInstallBtn.Content = Properties.Resources.Installing;
|
vigemInstallBtn.Content = Properties.Resources.Installing;
|
||||||
|
success = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (success)
|
||||||
|
{
|
||||||
monitorTimer = new NonFormTimer();
|
monitorTimer = new NonFormTimer();
|
||||||
monitorTimer.Elapsed += ViGEmInstallTimer_Tick;
|
monitorTimer.Elapsed += ViGEmInstallTimer_Tick;
|
||||||
monitorTimer.Start();
|
monitorTimer.Start();
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
vigemInstallBtn.Content = Properties.Resources.InstallFailed;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private void ViGEmInstallTimer_Tick(object sender, System.Timers.ElapsedEventArgs e)
|
private void ViGEmInstallTimer_Tick(object sender, System.Timers.ElapsedEventArgs e)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user