Replace getThemedIcon with APPLICATION->logo()
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
This commit is contained in:
@@ -147,7 +147,7 @@ AboutDialog::AboutDialog(QWidget* parent) : QDialog(parent), ui(new Ui::AboutDia
|
||||
|
||||
ui->urlLabel->setOpenExternalLinks(true);
|
||||
|
||||
ui->icon->setPixmap(APPLICATION->getThemedIcon("logo").pixmap(64));
|
||||
ui->icon->setPixmap(APPLICATION->logo().pixmap(64));
|
||||
ui->title->setText(launcherName);
|
||||
|
||||
ui->versionLabel->setText(BuildConfig.printableVersionString());
|
||||
|
||||
@@ -38,7 +38,6 @@
|
||||
#include <QLayout>
|
||||
#include <QPushButton>
|
||||
|
||||
#include "Application.h"
|
||||
#include "BuildConfig.h"
|
||||
#include "CreateShortcutDialog.h"
|
||||
#include "ui_CreateShortcutDialog.h"
|
||||
@@ -112,7 +111,7 @@ CreateShortcutDialog::CreateShortcutDialog(InstancePtr instance, QWidget* parent
|
||||
if (account->isInUse())
|
||||
profileLabel = tr("%1 (in use)").arg(profileLabel);
|
||||
auto face = account->getFace();
|
||||
QIcon icon = face.isNull() ? APPLICATION->getThemedIcon("noaccount") : face;
|
||||
QIcon icon = face.isNull() ? QIcon::fromTheme("noaccount") : face;
|
||||
ui->accountSelectionBox->addItem(profileLabel, account->profileName());
|
||||
ui->accountSelectionBox->setItemIcon(i, icon);
|
||||
if (defaultAccount == account)
|
||||
|
||||
@@ -53,7 +53,7 @@ class InstallLoaderPage : public VersionSelectWidget, public BasePage {
|
||||
|
||||
QString id() const override { return uid; }
|
||||
QString displayName() const override { return name; }
|
||||
QIcon icon() const override { return APPLICATION->getThemedIcon(iconName); }
|
||||
QIcon icon() const override { return QIcon::fromTheme(iconName); }
|
||||
|
||||
void openedImpl() override
|
||||
{
|
||||
|
||||
@@ -74,7 +74,7 @@ NewInstanceDialog::NewInstanceDialog(const QString& initialGroup,
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
setWindowIcon(APPLICATION->getThemedIcon("new"));
|
||||
setWindowIcon(QIcon::fromTheme("new"));
|
||||
|
||||
InstIconKey = "default";
|
||||
ui->iconButton->setIcon(APPLICATION->icons()->getIcon(InstIconKey));
|
||||
|
||||
@@ -55,9 +55,9 @@ ProfileSetupDialog::ProfileSetupDialog(MinecraftAccountPtr accountToSetup, QWidg
|
||||
ui->setupUi(this);
|
||||
ui->errorLabel->setVisible(false);
|
||||
|
||||
goodIcon = APPLICATION->getThemedIcon("status-good");
|
||||
yellowIcon = APPLICATION->getThemedIcon("status-yellow");
|
||||
badIcon = APPLICATION->getThemedIcon("status-bad");
|
||||
goodIcon = QIcon::fromTheme("status-good");
|
||||
yellowIcon = QIcon::fromTheme("status-yellow");
|
||||
badIcon = QIcon::fromTheme("status-bad");
|
||||
|
||||
static const QRegularExpression s_permittedNames("[a-zA-Z0-9_]{3,16}");
|
||||
auto nameEdit = ui->nameEdit;
|
||||
|
||||
@@ -59,7 +59,7 @@ ResourceDownloadDialog::ResourceDownloadDialog(QWidget* parent, const std::share
|
||||
|
||||
resize(static_cast<int>(std::max(0.5 * parent->width(), 400.0)), static_cast<int>(std::max(0.75 * parent->height(), 400.0)));
|
||||
|
||||
setWindowIcon(APPLICATION->getThemedIcon("new"));
|
||||
setWindowIcon(QIcon::fromTheme("new"));
|
||||
|
||||
// Bonk Qt over its stupid head and make sure it understands which button is the default one...
|
||||
// See: https://stackoverflow.com/questions/24556831/qbuttonbox-set-default-button
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
#include "ReviewMessageBox.h"
|
||||
#include "ui_ReviewMessageBox.h"
|
||||
|
||||
#include "Application.h"
|
||||
|
||||
#include <QPushButton>
|
||||
|
||||
ReviewMessageBox::ReviewMessageBox(QWidget* parent, [[maybe_unused]] QString const& title, [[maybe_unused]] QString const& icon)
|
||||
@@ -56,7 +54,7 @@ void ReviewMessageBox::appendResource(ResourceInformation&& info)
|
||||
|
||||
itemTop->insertChildren(1, { customPathItem });
|
||||
|
||||
itemTop->setIcon(1, QIcon(APPLICATION->getThemedIcon("status-yellow")));
|
||||
itemTop->setIcon(1, QIcon(QIcon::fromTheme("status-yellow")));
|
||||
itemTop->setToolTip(
|
||||
childIndx++,
|
||||
tr("This file will be downloaded to a folder location different from the default, possibly due to its loader requiring it."));
|
||||
|
||||
@@ -22,7 +22,6 @@
|
||||
|
||||
#include "UpdateAvailableDialog.h"
|
||||
#include <QPushButton>
|
||||
#include "Application.h"
|
||||
#include "BuildConfig.h"
|
||||
#include "Markdown.h"
|
||||
#include "StringUtils.h"
|
||||
@@ -41,7 +40,7 @@ UpdateAvailableDialog::UpdateAvailableDialog(const QString& currentVersion,
|
||||
ui->headerLabel->setText(tr("A new version of %1 is available!").arg(launcherName));
|
||||
ui->versionAvailableLabel->setText(
|
||||
tr("Version %1 is now available - you have %2 . Would you like to download it now?").arg(availableVersion).arg(currentVersion));
|
||||
ui->icon->setPixmap(APPLICATION->getThemedIcon("checkupdate").pixmap(64));
|
||||
ui->icon->setPixmap(QIcon::fromTheme("checkupdate").pixmap(64));
|
||||
|
||||
auto releaseNotesHtml = markdownToHTML(releaseNotes);
|
||||
ui->releaseNotes->setHtml(StringUtils::htmlListPatch(releaseNotesHtml));
|
||||
|
||||
Reference in New Issue
Block a user