aboutsummaryrefslogtreecommitdiff
path: root/src/yuzu/main.cpp
diff options
context:
space:
mode:
authorlizzie <lizzie@eden-emu.dev>2025-10-01 05:07:59 +0200
committercrueter <crueter@eden-emu.dev>2025-10-01 05:07:59 +0200
commit91fb1df624bdd58f4636c74cb6bc922325cebbbf (patch)
tree02ab8a4f5a47a5696727b5a62c8e3e45148590d0 /src/yuzu/main.cpp
parent43a7470a7d09ad412c7d9815ae23402f4bb7acb0 (diff)
[meta] allow customisation of auto-updater, remove hardcoded title names and fix dup title names (#2588)
Right now on all platforms, sdl2 will display something like "Eden Eden | master-8gd8fg8", this fixes so it only displays `Eden` (the REPO_NAME) once. Signed-off-by: lizzie <lizzie@eden-emu.dev> Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/2588 Reviewed-by: crueter <crueter@eden-emu.dev> Co-authored-by: lizzie <lizzie@eden-emu.dev> Co-committed-by: lizzie <lizzie@eden-emu.dev>
Diffstat (limited to 'src/yuzu/main.cpp')
-rw-r--r--src/yuzu/main.cpp20
1 files changed, 11 insertions, 9 deletions
diff --git a/src/yuzu/main.cpp b/src/yuzu/main.cpp
index d2c12c9d40..71cc0a7e6b 100644
--- a/src/yuzu/main.cpp
+++ b/src/yuzu/main.cpp
@@ -4192,23 +4192,25 @@ void GMainWindow::OnEmulatorUpdateAvailable() {
update_prompt.addButton(QMessageBox::Yes);
update_prompt.addButton(QMessageBox::Ignore);
update_prompt.setText(
- tr("Update %1 for Eden is available.\nWould you like to download it?").arg(version_string));
+ tr("Download the %1 update?").arg(version_string));
update_prompt.exec();
if (update_prompt.button(QMessageBox::Yes) == update_prompt.clickedButton()) {
- QDesktopServices::openUrl(
- QUrl(QString::fromStdString("https://github.com/eden-emulator/Releases/releases/tag/") +
- version_string));
+ auto const full_url = fmt::format("{}/{}/releases/tag/",
+ std::string{Common::g_build_auto_update_website},
+ std::string{Common::g_build_auto_update_repo}
+ );
+ QDesktopServices::openUrl(QUrl(QString::fromStdString(full_url) + version_string));
}
}
#endif
void GMainWindow::UpdateWindowTitle(std::string_view title_name, std::string_view title_version,
std::string_view gpu_vendor) {
- static const std::string description = std::string{Common::g_build_version};
- static const std::string build_id = std::string{Common::g_build_id};
- static const std::string compiler = std::string{Common::g_compiler_id};
-
- static const std::string yuzu_title = fmt::format("Eden | {} | {}", description, compiler);
+ static const std::string yuzu_title = fmt::format("{} | {} | {}",
+ std::string{Common::g_build_name},
+ std::string{Common::g_build_version},
+ std::string{Common::g_compiler_id}
+ );
const auto override_title =
fmt::format(fmt::runtime(std::string(Common::g_title_bar_format_idle)), build_id);