mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
Include user's operating system information in the About page (#3663)
Co-authored-by: Rasmus Karlsson <rasmus.karlsson@pajlada.com>
This commit is contained in:
parent
c399d4dbe9
commit
45e8d1d96e
|
@ -5,6 +5,7 @@
|
|||
- Minor: Added quotation marks in the permitted/blocked Automod messages for clarity. (#3654)
|
||||
- Minor: Adjust large stream thumbnail to 16:9 (#3655)
|
||||
- Minor: Fixed being unable to load Twitch Usercards from the `/mentions` tab. (#3623)
|
||||
- Minor: Add information about the user's operating system in the About page. (#3663)
|
||||
- Bugfix: Fixed live notifications for usernames containing uppercase characters. (#3646)
|
||||
- Dev: Use Game Name returned by Get Streams instead of querying it from the Get Games API. (#3662)
|
||||
|
||||
|
|
|
@ -85,16 +85,35 @@ AboutPage::AboutPage()
|
|||
auto versionInfo = layout.emplace<QGroupBox>("Version");
|
||||
{
|
||||
auto version = Version::instance();
|
||||
QString text = QString("%1 (commit %2%3)")
|
||||
.arg(version.fullVersion())
|
||||
.arg("<a "
|
||||
"href=\"https://github.com/Chatterino/"
|
||||
"chatterino2/commit/" +
|
||||
version.commitHash() + "\">" +
|
||||
version.commitHash() + "</a>")
|
||||
.arg(Modes::instance().isNightly
|
||||
? ", built on " + version.dateOfBuild()
|
||||
: "");
|
||||
QString osInfo = QSysInfo::prettyProductName() +
|
||||
", kernel: " + QSysInfo::kernelVersion();
|
||||
if (version.isFlatpak())
|
||||
{
|
||||
osInfo += ", running from Flatpak";
|
||||
}
|
||||
|
||||
QString commitHashLink =
|
||||
QString("<a "
|
||||
"href=\"https://github.com/Chatterino/chatterino2/"
|
||||
"commit/%1\">%1</a>")
|
||||
.arg(version.commitHash());
|
||||
|
||||
QString nightlyBuildInfo;
|
||||
if (Modes::instance().isNightly)
|
||||
{
|
||||
nightlyBuildInfo =
|
||||
QString(", built on %1").arg(version.dateOfBuild());
|
||||
}
|
||||
|
||||
QString supportedOS;
|
||||
if (!version.isSupportedOS())
|
||||
{
|
||||
supportedOS = "(unsupported OS)";
|
||||
}
|
||||
|
||||
QString text = QString("%1 (commit %2%3) running on %4 %5")
|
||||
.arg(version.fullVersion(), commitHashLink,
|
||||
nightlyBuildInfo, osInfo, supportedOS);
|
||||
|
||||
auto versionLabel = versionInfo.emplace<QLabel>(text);
|
||||
versionLabel->setOpenExternalLinks(true);
|
||||
|
|
Loading…
Reference in a new issue