Commit 6af4fff4 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

kde4 Migration code will be removed in kf6

parent 6d0edc12
Pipeline #59127 passed with stage
in 10 minutes and 45 seconds
...@@ -28,7 +28,10 @@ ...@@ -28,7 +28,10 @@
#include <KLocalizedString> #include <KLocalizedString>
#include <KAboutData> #include <KAboutData>
#include <kcoreaddons_version.h>
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
#include <Kdelibs4ConfigMigrator> #include <Kdelibs4ConfigMigrator>
#endif
#include <QCommandLineParser> #include <QCommandLineParser>
#include <QNetworkConfiguration> #include <QNetworkConfiguration>
...@@ -337,11 +340,11 @@ AgentBasePrivate::~AgentBasePrivate() ...@@ -337,11 +340,11 @@ AgentBasePrivate::~AgentBasePrivate()
void AgentBasePrivate::init() void AgentBasePrivate::init()
{ {
Q_Q(AgentBase); Q_Q(AgentBase);
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
Kdelibs4ConfigMigrator migrate(mId); Kdelibs4ConfigMigrator migrate(mId);
migrate.setConfigFiles(QStringList() << QStringLiteral("%1rc").arg(mId)); migrate.setConfigFiles(QStringList() << QStringLiteral("%1rc").arg(mId));
migrate.migrate(); migrate.migrate();
#endif
/** /**
* Create a default session for this process. * Create a default session for this process.
*/ */
......
...@@ -15,7 +15,10 @@ ...@@ -15,7 +15,10 @@
#include "akonadicore_debug.h" #include "akonadicore_debug.h"
#include <KLocalizedString> #include <KLocalizedString>
#include <kcoreaddons_version.h>
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
#include <Kdelibs4ConfigMigrator> #include <Kdelibs4ConfigMigrator>
#endif
#include "private/dbus_p.h" #include "private/dbus_p.h"
#include "private/instance_p.h" #include "private/instance_p.h"
...@@ -111,10 +114,11 @@ Q_GLOBAL_STATIC(ServerManagerPrivate, sInstance) // NOLINT(readability-redundant ...@@ -111,10 +114,11 @@ Q_GLOBAL_STATIC(ServerManagerPrivate, sInstance) // NOLINT(readability-redundant
ServerManager::ServerManager(ServerManagerPrivate *dd) ServerManager::ServerManager(ServerManagerPrivate *dd)
: d(dd) : d(dd)
{ {
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
Kdelibs4ConfigMigrator migrate(QStringLiteral("servermanager")); Kdelibs4ConfigMigrator migrate(QStringLiteral("servermanager"));
migrate.setConfigFiles(QStringList() << QStringLiteral("akonadi-firstrunrc")); migrate.setConfigFiles(QStringList() << QStringLiteral("akonadi-firstrunrc"));
migrate.migrate(); migrate.migrate();
#endif
qRegisterMetaType<Akonadi::ServerManager::State>(); qRegisterMetaType<Akonadi::ServerManager::State>();
d->serviceWatcher = std::make_unique<QDBusServiceWatcher>(ServerManager::serviceName(ServerManager::Server), d->serviceWatcher = std::make_unique<QDBusServiceWatcher>(ServerManager::serviceName(ServerManager::Server),
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment