mirror of
https://github.com/cemu-project/DS4Windows.git
synced 2025-01-23 13:41:15 +01:00
Change download location of updater
This commit is contained in:
parent
eae1d47ba6
commit
d2324eabc5
@ -63,7 +63,7 @@ namespace DS4Windows
|
|||||||
{ "DS4Windows v" + FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).FileVersion,
|
{ "DS4Windows v" + FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).FileVersion,
|
||||||
string.Empty, string.Empty, string.Empty, string.Empty };
|
string.Empty, string.Empty, string.Empty, string.Empty };
|
||||||
|
|
||||||
private const string UPDATER_VERSION = "1.2.9.0";
|
private const string UPDATER_VERSION = "1.2.9";
|
||||||
private const int WM_QUERYENDSESSION = 0x11;
|
private const int WM_QUERYENDSESSION = 0x11;
|
||||||
private const int WM_CLOSE = 0x10;
|
private const int WM_CLOSE = 0x10;
|
||||||
internal string updaterExe = Environment.Is64BitProcess ? "DS4Updater.exe" : "DS4Updater_x86.exe";
|
internal string updaterExe = Environment.Is64BitProcess ? "DS4Updater.exe" : "DS4Updater_x86.exe";
|
||||||
@ -770,14 +770,14 @@ Properties.Resources.DS4Update, MessageBoxButtons.YesNo, MessageBoxIcon.Question
|
|||||||
if (!File.Exists(exepath + "\\DS4Updater.exe") || (File.Exists(exepath + "\\DS4Updater.exe")
|
if (!File.Exists(exepath + "\\DS4Updater.exe") || (File.Exists(exepath + "\\DS4Updater.exe")
|
||||||
&& (FileVersionInfo.GetVersionInfo(exepath + "\\DS4Updater.exe").FileVersion.CompareTo(UPDATER_VERSION) != 0)))
|
&& (FileVersionInfo.GetVersionInfo(exepath + "\\DS4Updater.exe").FileVersion.CompareTo(UPDATER_VERSION) != 0)))
|
||||||
{
|
{
|
||||||
Uri url2 = new Uri($"http://23.239.26.40/ds4windows/files/{updaterExe}");
|
Uri url2 = new Uri($"http://github.com/Ryochan7/DS4Updater/releases/download/v{UPDATER_VERSION}/{updaterExe}");
|
||||||
WebClient wc2 = new WebClient();
|
WebClient wc2 = new WebClient();
|
||||||
if (appdatapath == exepath)
|
if (appdatapath == exepath)
|
||||||
wc2.DownloadFile(url2, exepath + "\\DS4Updater.exe");
|
wc2.DownloadFile(url2, exepath + "\\DS4Updater.exe");
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this.BeginInvoke((System.Action)(() => MessageBox.Show(Properties.Resources.PleaseDownloadUpdater)));
|
this.BeginInvoke((System.Action)(() => MessageBox.Show(Properties.Resources.PleaseDownloadUpdater)));
|
||||||
Process.Start($"http://23.239.26.40/ds4windows/files/{updaterExe}");
|
Process.Start($"http://github.com/Ryochan7/DS4Updater/releases/download/v{UPDATER_VERSION}/{updaterExe}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2086,14 +2086,14 @@ Properties.Resources.DS4Update, MessageBoxButtons.YesNo, MessageBoxIcon.Question
|
|||||||
if (!File.Exists(exepath + "\\DS4Updater.exe") || (File.Exists(exepath + "\\DS4Updater.exe")
|
if (!File.Exists(exepath + "\\DS4Updater.exe") || (File.Exists(exepath + "\\DS4Updater.exe")
|
||||||
&& (FileVersionInfo.GetVersionInfo(exepath + "\\DS4Updater.exe").FileVersion.CompareTo(UPDATER_VERSION) != 0)))
|
&& (FileVersionInfo.GetVersionInfo(exepath + "\\DS4Updater.exe").FileVersion.CompareTo(UPDATER_VERSION) != 0)))
|
||||||
{
|
{
|
||||||
Uri url2 = new Uri($"http://23.239.26.40/ds4windows/files/{updaterExe}");
|
Uri url2 = new Uri($"http://github.com/Ryochan7/DS4Updater/releases/download/v{UPDATER_VERSION}/{updaterExe}");
|
||||||
WebClient wc2 = new WebClient();
|
WebClient wc2 = new WebClient();
|
||||||
if (appdatapath == exepath)
|
if (appdatapath == exepath)
|
||||||
wc2.DownloadFile(url2, exepath + "\\DS4Updater.exe");
|
wc2.DownloadFile(url2, exepath + "\\DS4Updater.exe");
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
this.BeginInvoke((System.Action)(() => MessageBox.Show(Properties.Resources.PleaseDownloadUpdater)));
|
this.BeginInvoke((System.Action)(() => MessageBox.Show(Properties.Resources.PleaseDownloadUpdater)));
|
||||||
Process.Start($"http://23.239.26.40/ds4windows/files/{updaterExe}");
|
Process.Start($"http://github.com/Ryochan7/DS4Updater/releases/download/v{UPDATER_VERSION}/{updaterExe}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user