diff --git a/cockatrice/src/main.cpp b/cockatrice/src/main.cpp index 89abee12..69003a3d 100644 --- a/cockatrice/src/main.cpp +++ b/cockatrice/src/main.cpp @@ -151,6 +151,10 @@ int main(int argc, char *argv[]) qDebug("main(): MainWindow constructor finished"); ui.setWindowIcon(QPixmap("theme:cockatrice")); +#if QT_VERSION >= QT_VERSION_CHECK(5, 7, 0) + // set name of the app desktop file; used by wayland to load the window icon + QGuiApplication::setDesktopFileName("cockatrice"); +#endif SettingsCache::instance().setClientID(generateClientID()); diff --git a/oracle/src/main.cpp b/oracle/src/main.cpp index b26c339d..6cae0b6d 100644 --- a/oracle/src/main.cpp +++ b/oracle/src/main.cpp @@ -62,6 +62,10 @@ int main(int argc, char *argv[]) QIcon icon("theme:appicon.svg"); wizard.setWindowIcon(icon); +#if QT_VERSION >= QT_VERSION_CHECK(5, 7, 0) + // set name of the app desktop file; used by wayland to load the window icon + QGuiApplication::setDesktopFileName("oracle"); +#endif wizard.show();