#include <KLocalizedString>
#include <KWindowSystem>
-#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
-#include <Kdelibs4ConfigMigrator>
-#endif
-
#define HAVE_STYLE_MANAGER __has_include(<KStyleManager>)
#if HAVE_STYLE_MANAGER
#include <KStyleManager>
#include <QSessionManager>
#if HAVE_X11
-#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
#include <private/qtx11extras_p.h>
-#else
-#include <QX11Info>
-#endif
#endif
#ifndef Q_OS_WIN
/**
* trigger initialisation of proper icon theme
*/
-#if KICONTHEMES_VERSION >= QT_VERSION_CHECK(6, 3, 0)
KIconTheme::initTheme();
-#endif
- /**
- * enable high dpi support
- */
-#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
- QCoreApplication::setAttribute(Qt::AA_UseHighDpiPixmaps, true);
- QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling, true);
-#endif
QApplication app(argc, argv);
app.setWindowIcon(QIcon::fromTheme(QStringLiteral("system-file-manager"), app.windowIcon()));
#endif
#endif
- KCrash::initialize();
-
-#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
- Kdelibs4ConfigMigrator migrate(QStringLiteral("dolphin"));
- migrate.setConfigFiles(QStringList() << QStringLiteral("dolphinrc"));
- migrate.setUiFiles(QStringList() << QStringLiteral("dolphinpart.rc") << QStringLiteral("dolphinui.rc"));
- migrate.migrate();
-#endif
-
KLocalizedString::setApplicationDomain(dolphinTranslationDomain);
KAboutData aboutData(QStringLiteral("dolphin"),
QStringLiteral(DOLPHIN_VERSION_STRING),
i18nc("@title", "File Manager"),
KAboutLicense::GPL,
- i18nc("@info:credit", "(C) 2006-2022 The Dolphin Developers"));
+ i18nc("@info:credit", "(C) 2006-2025 The Dolphin Developers"));
aboutData.setHomepage(QStringLiteral("https://apps.kde.org/dolphin"));
aboutData.addAuthor(i18nc("@info:credit", "Felix Ernst"),
i18nc("@info:credit", "Maintainer (since 2021) and developer"),
aboutData.addAuthor(i18nc("@info:credit", "Michael Austin"), i18nc("@info:credit", "Documentation"), QStringLiteral("tuxedup@users.sourceforge.net"));
KAboutData::setApplicationData(aboutData);
+ KCrash::initialize();
QCommandLineParser parser;
aboutData.setupCommandLine(&parser);
}
if (parser.isSet(QStringLiteral("daemon"))) {
+ // Prevent KApplicationLauncherJob from cause the application to quit on job finish.
+ QCoreApplication::setQuitLockEnabled(false);
+
// Disable session management for the daemonized version
// See https://bugs.kde.org/show_bug.cgi?id=417219
auto disableSessionManagement = [](QSessionManager &sm) {