diff --git a/launcher/ui/dialogs/AboutDialog.cpp b/launcher/ui/dialogs/AboutDialog.cpp index d071da9a..81d1d7f7 100644 --- a/launcher/ui/dialogs/AboutDialog.cpp +++ b/launcher/ui/dialogs/AboutDialog.cpp @@ -21,10 +21,23 @@ #include "BuildConfig.h" #include +#include #include "HoeDown.h" namespace { +QString getLink(QString link, QString name) { + return QString("<%2>").arg(link).arg(name); +} + +QString getWebsite(QString link) { + return getLink(link, QObject::tr("Website")); +} + +QString getGitHub(QString username) { + return getLink("https://github.com/" + username, "GitHub"); +} + // Credits // This is a hack, but I can't think of a better way to do this easily without screwing with QTextDocument... QString getCreditsHtml() @@ -36,8 +49,20 @@ QString getCreditsHtml() //: %1 is the name of the launcher, determined at build time, e.g. "PolyMC Developers" stream << "

" << QObject::tr("%1 Developers", "About Credits").arg(BuildConfig.LAUNCHER_NAME) << "

\n"; - stream << "

swirl <swurl@swurl.xyz >

\n"; - stream << "

LennyMcLennington <lenny@sneed.church>

\n"; + stream << QString("

LennyMcLennington %1

\n") .arg(getGitHub("LennyMcLennington")); + stream << QString("

Sefa Eyeoglu (Scrumplex) %1

\n") .arg(getWebsite("https://scrumplex.net")); + stream << QString("

dada513 %1

\n") .arg(getGitHub("dada513")); + stream << QString("

txtsd %1

\n") .arg(getGitHub("txtsd")); + stream << QString("

timoreo %1

\n") .arg(getGitHub("timoreo22")); + stream << QString("

Ezekiel Smith (ZekeSmith) %1

\n") .arg(getGitHub("ZekeSmith")); + stream << QString("

cozyGalvinism %1

\n") .arg(getGitHub("cozyGalvinism")); + stream << "
\n"; + + //: %1 is the name of the launcher, determined at build time, e.g. "PolyMC Contributors" + stream << "

" << QObject::tr("%1 Contributors", "About Credits").arg(BuildConfig.LAUNCHER_NAME) << "

\n"; + stream << QString("

DioEgizio %1

\n") .arg(getGitHub("DioEgizio")); + stream << QString("

flowln %1

\n") .arg(getGitHub("flowln")); + stream << QString("

swirl %1

\n") .arg(getWebsite("https://swurl.xyz/")); stream << "
\n"; // TODO: possibly retrieve from git history at build time? diff --git a/launcher/ui/dialogs/AboutDialog.ui b/launcher/ui/dialogs/AboutDialog.ui index 58275c66..f9665c30 100644 --- a/launcher/ui/dialogs/AboutDialog.ui +++ b/launcher/ui/dialogs/AboutDialog.ui @@ -87,7 +87,7 @@ - + Qt::AlignCenter @@ -209,13 +209,10 @@ - - + + true - - Qt::TextBrowserInteraction -