summaryrefslogtreecommitdiffstats
path: root/rbutil/rbutilqt/base/systeminfo.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'rbutil/rbutilqt/base/systeminfo.cpp')
-rw-r--r--rbutil/rbutilqt/base/systeminfo.cpp55
1 files changed, 32 insertions, 23 deletions
diff --git a/rbutil/rbutilqt/base/systeminfo.cpp b/rbutil/rbutilqt/base/systeminfo.cpp
index 67b0428ceb..2aece49110 100644
--- a/rbutil/rbutilqt/base/systeminfo.cpp
+++ b/rbutil/rbutilqt/base/systeminfo.cpp
@@ -27,28 +27,23 @@ const static struct {
SystemInfo::SystemInfos info;
const char* name;
} SystemInfosList[] = {
- { SystemInfo::ManualUrl, "manual_url" },
- { SystemInfo::BleedingUrl, "bleeding_url" },
- { SystemInfo::BootloaderUrl, "bootloader_url" },
- { SystemInfo::BootloaderInfoUrl, "bootloader_info_url" },
- { SystemInfo::ReleaseFontUrl, "release_font_url" },
- { SystemInfo::DailyFontUrl, "daily_font_url" },
- { SystemInfo::DailyVoiceUrl, "daily_voice_url" },
- { SystemInfo::ReleaseVoiceUrl, "release_voice_url" },
- { SystemInfo::DoomUrl, "doom_url" },
- { SystemInfo::Duke3DUrl, "duke3d_url" },
- { SystemInfo::PuzzFontsUrl, "puzzfonts_url" },
- { SystemInfo::QuakeUrl, "quake_url" },
- { SystemInfo::Wolf3DUrl, "wolf3d_url" },
- { SystemInfo::XWorldUrl, "xworld_url" },
- { SystemInfo::ReleaseUrl, "release_url" },
- { SystemInfo::CandidateUrl, "rc_url" },
- { SystemInfo::DailyUrl, "daily_url" },
- { SystemInfo::BuildInfoUrl, "build_info_url" },
- { SystemInfo::GenlangUrl, "genlang_url" },
- { SystemInfo::ThemesUrl, "themes_url" },
- { SystemInfo::ThemesInfoUrl, "themes_info_url" },
- { SystemInfo::RbutilUrl, "rbutil_url" },
+ { SystemInfo::ManualUrl, ":build:/manual_url" },
+ { SystemInfo::BuildUrl, ":build:/build_url" },
+ { SystemInfo::FontUrl, ":build:/font_url" },
+ { SystemInfo::VoiceUrl, ":build:/voice_url" },
+ { SystemInfo::BootloaderUrl, "bootloader/download_url" },
+ { SystemInfo::BootloaderInfoUrl, "bootloader/info_url" },
+ { SystemInfo::DoomUrl, "doom_url" },
+ { SystemInfo::Duke3DUrl, "duke3d_url" },
+ { SystemInfo::PuzzFontsUrl, "puzzfonts_url" },
+ { SystemInfo::QuakeUrl, "quake_url" },
+ { SystemInfo::Wolf3DUrl, "wolf3d_url" },
+ { SystemInfo::XWorldUrl, "xworld_url" },
+ { SystemInfo::BuildInfoUrl, "build_info_url" },
+ { SystemInfo::GenlangUrl, "genlang_url" },
+ { SystemInfo::ThemesUrl, "themes_url" },
+ { SystemInfo::ThemesInfoUrl, "themes_info_url" },
+ { SystemInfo::RbutilUrl, "rbutil_url" },
};
const static struct {
@@ -84,7 +79,7 @@ void SystemInfo::ensureSystemInfoExists()
}
-QVariant SystemInfo::value(enum SystemInfos info)
+QVariant SystemInfo::value(enum SystemInfos info, BuildType type)
{
ensureSystemInfoExists();
@@ -93,6 +88,20 @@ QVariant SystemInfo::value(enum SystemInfos info)
while(SystemInfosList[i].info != info)
i++;
QString s = SystemInfosList[i].name;
+ switch(type) {
+ case BuildDaily:
+ s.replace(":build:", "daily");
+ break;
+ case BuildCurrent:
+ s.replace(":build:", "development");
+ break;
+ case BuildCandidate:
+ s.replace(":build:", "release-candidate");
+ break;
+ case BuildRelease:
+ s.replace(":build:", "release");
+ break;
+ }
LOG_INFO() << "GET:" << s << systemInfos->value(s).toString();
return systemInfos->value(s);
}