Commit cb7fdf27 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

In kf6 kde4 migration code will be removed

parent 1b58b539
Pipeline #59128 failed with stage
in 25 minutes and 9 seconds
...@@ -23,7 +23,10 @@ ...@@ -23,7 +23,10 @@
#include <KLocalizedString> #include <KLocalizedString>
#include <KMime/Message> #include <KMime/Message>
#include <KNotification> #include <KNotification>
#include <kcoreaddons_version.h>
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
#include <Kdelibs4ConfigMigrator> #include <Kdelibs4ConfigMigrator>
#endif
#include <QDBusConnection> #include <QDBusConnection>
#include <QTimer> #include <QTimer>
...@@ -117,10 +120,11 @@ void MailDispatcherAgent::dispatch() ...@@ -117,10 +120,11 @@ void MailDispatcherAgent::dispatch()
MailDispatcherAgent::MailDispatcherAgent(const QString &id) MailDispatcherAgent::MailDispatcherAgent(const QString &id)
: AgentBase(id) : AgentBase(id)
{ {
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
Kdelibs4ConfigMigrator migrate(QStringLiteral("maildispatcheragent")); Kdelibs4ConfigMigrator migrate(QStringLiteral("maildispatcheragent"));
migrate.setConfigFiles(QStringList() << QStringLiteral("maildispatcheragentrc") << QStringLiteral("akonadi_maildispatcher_agent.notifyrc")); migrate.setConfigFiles(QStringList() << QStringLiteral("maildispatcheragentrc") << QStringLiteral("akonadi_maildispatcher_agent.notifyrc"));
migrate.migrate(); migrate.migrate();
#endif
qCDebug(MAILDISPATCHER_LOG) << "maildispatcheragent: At your service, sir!"; qCDebug(MAILDISPATCHER_LOG) << "maildispatcheragent: At your service, sir!";
new SettingsAdaptor(Settings::self()); new SettingsAdaptor(Settings::self());
......
...@@ -32,7 +32,10 @@ ...@@ -32,7 +32,10 @@
#include <KLocalizedString> #include <KLocalizedString>
#include <KMime/Message> #include <KMime/Message>
#include <KNotification> #include <KNotification>
#include <kcoreaddons_version.h>
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
#include <Kdelibs4ConfigMigrator> #include <Kdelibs4ConfigMigrator>
#endif
#include <QTextToSpeech> #include <QTextToSpeech>
using namespace Akonadi; using namespace Akonadi;
...@@ -40,9 +43,11 @@ using namespace Akonadi; ...@@ -40,9 +43,11 @@ using namespace Akonadi;
NewMailNotifierAgent::NewMailNotifierAgent(const QString &id) NewMailNotifierAgent::NewMailNotifierAgent(const QString &id)
: AgentBase(id) : AgentBase(id)
{ {
#if KCOREADDONS_VERSION < QT_VERSION_CHECK(6, 0, 0)
Kdelibs4ConfigMigrator migrate(QStringLiteral("newmailnotifieragent")); Kdelibs4ConfigMigrator migrate(QStringLiteral("newmailnotifieragent"));
migrate.setConfigFiles(QStringList() << QStringLiteral("akonadi_newmailnotifier_agentrc") << QStringLiteral("akonadi_newmailnotifier_agent.notifyrc")); migrate.setConfigFiles(QStringList() << QStringLiteral("akonadi_newmailnotifier_agentrc") << QStringLiteral("akonadi_newmailnotifier_agent.notifyrc"));
migrate.migrate(); migrate.migrate();
#endif
connect(this, &Akonadi::AgentBase::reloadConfiguration, this, &NewMailNotifierAgent::slotReloadConfiguration); connect(this, &Akonadi::AgentBase::reloadConfiguration, this, &NewMailNotifierAgent::slotReloadConfiguration);
KLocalizedString::setApplicationDomain("akonadi_newmailnotifier_agent"); KLocalizedString::setApplicationDomain("akonadi_newmailnotifier_agent");
Akonadi::AttributeFactory::registerAttribute<Akonadi::NewMailNotifierAttribute>(); Akonadi::AttributeFactory::registerAttribute<Akonadi::NewMailNotifierAttribute>();
......
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