Implement opening external package link.

This commit is contained in:
2023-07-03 01:10:45 +08:00
parent 864ea91be0
commit 83b9c27e94
5 changed files with 77 additions and 1 deletions

View File

@@ -77,7 +77,10 @@ namespace Cryville.Crtr.Network {
}
}
if (totalDiffSize == 0 || totalDiffSize >= fullPackage.size) {
Dialog.ShowAndWait(string.Format("A new version is available: {0}\nYou have to download the full package.\nOpen the download link now?", latestVersion.name), "Yes", "No");
// TODO Check if external
if (Dialog.ShowAndWait(string.Format("A new version is available: {0}\nYou have to download the full package.\nOpen the download link now?", latestVersion.name), "Yes", "No") == 0) {
UrlOpener.Open(fullPackage.url);
}
}
else {
Dialog.ShowAndWait(string.Format("A new version is available: {0}\nDo you want to update?", latestVersion.name), "Yes", "No");