Skip to content

Commit

Permalink
Icon fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
rodlie committed May 30, 2024
1 parent 3a25422 commit ed8eccb
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/app/GUI/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1133,7 +1133,7 @@ void MainWindow::setupMenuBar()

const auto help = mMenuBar->addMenu(tr("Help", "MenuBar"));

const auto aboutAct = help->addAction(QIcon::fromTheme("friction"),
const auto aboutAct = help->addAction(QIcon::fromTheme(AppSupport::getAppID()),
tr("About", "MenuBar_Help"),
this,
&MainWindow::openAboutWindow);
Expand Down Expand Up @@ -1162,7 +1162,7 @@ void MainWindow::setupMenuBar()
if (eSettings::instance().fCurrentInterfaceDPI != 1.) {
frictionButton->setIconSize(QSize(eSizesUI::widget, eSizesUI::widget));
}
frictionButton->setIcon(QIcon::fromTheme("friction"));
frictionButton->setIcon(QIcon::fromTheme(AppSupport::getAppID()));
frictionButton->setDefaultAction(aboutAct);
frictionButton->setToolTip(QString());
frictionButton->setFocusPolicy(Qt::NoFocus);
Expand Down Expand Up @@ -1992,7 +1992,7 @@ void MainWindow::updateRecentMenu()
for (const auto &path : mRecentFiles) {
QFileInfo info(path);
if (!info.exists()) { continue; }
mRecentMenu->addAction(QIcon::fromTheme("friction"), info.baseName(), [path, this]() {
mRecentMenu->addAction(QIcon::fromTheme(AppSupport::getAppID()), info.baseName(), [path, this]() {
openFile(path);
});
}
Expand Down
3 changes: 2 additions & 1 deletion src/core/GUI/edialogs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,12 @@
#include <QFileIconProvider>
#include <QFileSystemModel>
#include <QSortFilterProxyModel>
#include "appsupport.h"

class evIconProvider : public QFileIconProvider {
public:
evIconProvider() {
mEvIcon = QIcon::fromTheme("friction");
mEvIcon = QIcon::fromTheme(AppSupport::getAppID());
}

QIcon icon(const QFileInfo & info) const {
Expand Down
2 changes: 1 addition & 1 deletion src/core/appsupport.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ const QString AppSupport::getAppDomain()

const QString AppSupport::getAppID()
{
return QString::fromUtf8("graphics.friction");
return QString::fromUtf8("graphics.friction.Friction");
}

const QString AppSupport::getAppUrl()
Expand Down
2 changes: 1 addition & 1 deletion src/ui/widgets/aboutwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ AboutWidget::AboutWidget(QWidget *parent)
"</div>").arg(AppSupport::getAppVersion(),
QString::number(96),
AppSupport::getAppDisplayName(),
AppSupport::getAppName());
AppSupport::getAppID());
const auto buildInfo = AppSupport::getAppBuildInfo(true);
if (!buildInfo.isEmpty()) {
label.append(buildInfo);
Expand Down
2 changes: 1 addition & 1 deletion src/ui/widgets/welcomedialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ WelcomeDialog::WelcomeDialog(QMenu *recentMenu,
.arg(AppSupport::getAppVersion(),
QString::number(logoSize),
AppSupport::getAppDisplayName(),
AppSupport::getAppName()));
AppSupport::getAppID()));

const auto buttonWid = new QWidget(this);
buttonWid->setContentsMargins(0, 0, 0, 0);
Expand Down

0 comments on commit ed8eccb

Please sign in to comment.