From 4a3a379871c04193ff53ebb395f71155a82e309a Mon Sep 17 00:00:00 2001 From: Jonas Kvinge Date: Thu, 19 May 2022 22:02:35 +0200 Subject: [PATCH] Increase icons to include 128x128 and set global application icon Fixes #954 --- src/core/iconloader.cpp | 2 +- src/core/mainwindow.cpp | 2 ++ src/core/mainwindow.ui | 8 ++++---- src/main.cpp | 1 + 4 files changed, 8 insertions(+), 5 deletions(-) diff --git a/src/core/iconloader.cpp b/src/core/iconloader.cpp index c423d221e..c88dd4048 100644 --- a/src/core/iconloader.cpp +++ b/src/core/iconloader.cpp @@ -63,7 +63,7 @@ QIcon IconLoader::Load(const QString &name, const int fixed_size, const int min_ QList sizes; if (fixed_size == 0) { - sizes << 22 << 32 << 48 << 64; + sizes << 22 << 32 << 48 << 64 << 128; } else { sizes << fixed_size; diff --git a/src/core/mainwindow.cpp b/src/core/mainwindow.cpp index 402ebf8ff..2ec491912 100644 --- a/src/core/mainwindow.cpp +++ b/src/core/mainwindow.cpp @@ -346,6 +346,8 @@ MainWindow::MainWindow(Application *app, std::shared_ptr tray_ic // Initialize the UI ui_->setupUi(this); + setWindowIcon(IconLoader::Load("strawberry")); + album_cover_choice_controller_->Init(app); ui_->multi_loading_indicator->SetTaskManager(app_->task_manager()); diff --git a/src/core/mainwindow.ui b/src/core/mainwindow.ui index f9e2aa832..302538bfa 100644 --- a/src/core/mainwindow.ui +++ b/src/core/mainwindow.ui @@ -15,7 +15,7 @@ - :/icons/64x64/strawberry.png:/icons/64x64/strawberry.png + :/icons/128x128/strawberry.png:/icons/128x128/strawberry.png @@ -749,9 +749,9 @@ - - &Save all playlists - + + &Save all playlists + diff --git a/src/main.cpp b/src/main.cpp index 3dfd37846..6a01f3853 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -193,6 +193,7 @@ int main(int argc, char *argv[]) { return 0; } QGuiApplication::setQuitOnLastWindowClosed(false); + QGuiApplication::setWindowIcon(IconLoader::Load("strawberry")); #if defined(USE_BUNDLE) && (defined(Q_OS_LINUX) || defined(Q_OS_MACOS)) qLog(Debug) << "Looking for resources in" << QCoreApplication::applicationDirPath() + "/" + USE_BUNDLE_DIR;