mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2024-11-26 02:54:20 +01:00
Merge branch 'safer-startup' of https://github.com/almod90/DS4Windows into almod90-safer-startup
This commit is contained in:
commit
c1746410dc
@ -346,9 +346,18 @@ namespace DS4Windows.Forms
|
|||||||
|
|
||||||
if (onlylnkpath != Process.GetCurrentProcess().MainModule.FileName)
|
if (onlylnkpath != Process.GetCurrentProcess().MainModule.FileName)
|
||||||
{
|
{
|
||||||
File.Delete(Environment.GetFolderPath(Environment.SpecialFolder.Startup) + "\\DS4Windows.lnk");
|
try
|
||||||
appShortcutToStartup();
|
{
|
||||||
changeStartupRoutine();
|
File.Delete(Environment.GetFolderPath(Environment.SpecialFolder.Startup) + "\\DS4Windows.lnk");
|
||||||
|
appShortcutToStartup();
|
||||||
|
changeStartupRoutine();
|
||||||
|
}
|
||||||
|
catch
|
||||||
|
{
|
||||||
|
MessageBox.Show("No access to Autorun/DS4Windows.lnk\nPlease check file permissions", "DS4Windows");
|
||||||
|
StartWindowsCheckBox.Checked = false;
|
||||||
|
runStartupPanel.Visible = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user