1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2025-12-10 09:32:29 +01:00

'Update available' button should lead to openrct2.io

This commit is contained in:
Gymnasiast
2025-05-10 20:30:17 +02:00
parent 45a408c84f
commit 3641d80519
4 changed files with 3 additions and 4 deletions

View File

@@ -1,5 +1,6 @@
0.4.23 (in development)
------------------------------------------------------------------------
- Improved: [#24368] Clicking the in-game update notication now leads to a more user-friendly download page.
0.4.22 (2025-05-04)
------------------------------------------------------------------------

View File

@@ -165,7 +165,7 @@ namespace OpenRCT2::Ui::Windows
case WIDX_OPEN_URL:
if (_newVersionInfo != nullptr)
{
GetContext()->GetUiContext()->OpenURL(_newVersionInfo->url);
GetContext()->GetUiContext()->OpenURL("https://openrct2.io/download/release");
}
else
{

View File

@@ -70,7 +70,7 @@ NewVersionInfo GetLatestVersion()
// If the check doesn't succeed, provide current version so we don't bother user
// with invalid data.
std::string tag = gVersionInfoTag;
NewVersionInfo verinfo{ tag, "", "", "" };
NewVersionInfo verinfo{ tag, "", "" };
#if !defined(DISABLE_HTTP) && !defined(DISABLE_VERSION_CHECKER)
auto now = std::chrono::duration_cast<std::chrono::seconds>(std::chrono::system_clock::now().time_since_epoch()).count();
auto then = Config::Get().general.LastVersionCheckTime;
@@ -100,7 +100,6 @@ NewVersionInfo GetLatestVersion()
verinfo.tag = Json::GetString(root["tag_name"]);
verinfo.name = Json::GetString(root["name"]);
verinfo.changelog = Json::GetString(root["body"]);
verinfo.url = Json::GetString(root["html_url"]);
Config::Get().general.LastVersionCheckTime = now;
Config::Save();

View File

@@ -83,7 +83,6 @@ struct NewVersionInfo
std::string tag;
std::string name;
std::string changelog;
std::string url;
};
NewVersionInfo GetLatestVersion();