Commit 42e9896b authored by Laurent Montel's avatar Laurent Montel 😁

Use kdbusconnectionpool.h

parent 08d063fe
......@@ -54,7 +54,7 @@ include(ECMInstallIcons)
set(KF5_VERSION "5.4.0")
set(QT_REQUIRED_VERSION "5.3.0")
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
set(KDEPIMRUNTIME_LIB_VERSION "4.70.0")
set(KDEPIMRUNTIME_LIB_SOVERSION "5")
......
......@@ -17,7 +17,7 @@ if ("${CMAKE_SOURCE_DIR}" STREQUAL "${accountwizard_SOURCE_DIR}")
# FIXME: Do we want the same versions in kdepimlibs and kf5?
set(KF5_VERSION "5.4.0")
set(QT_REQUIRED_VERSION "5.3.0")
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
# KF5 package
find_package(KF5KIO ${KF5_VERSION} CONFIG REQUIRED)
......
......@@ -16,7 +16,7 @@ if ("${CMAKE_SOURCE_DIR}" STREQUAL "${agents_SOURCE_DIR}")
include(KDECMakeSettings)
include(KDEFrameworkCompilerSettings)
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
set(KF5_VERSION "5.4.0")
set(QT_REQUIRED_VERSION "5.3.0")
# KF5 package
......
......@@ -29,7 +29,7 @@
#include "settingsadaptor.h"
#include <agentfactory.h>
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <itemfetchscope.h>
#include <mailtransport/sentactionattribute.h>
......@@ -194,12 +194,12 @@ MailDispatcherAgent::MailDispatcherAgent( const QString &id )
new SettingsAdaptor( Settings::self() );
new MailDispatcherAgentAdaptor( this );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
Settings::self(), QDBusConnection::ExportAdaptors );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/MailDispatcherAgent" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/MailDispatcherAgent" ),
this, QDBusConnection::ExportAdaptors );
DBusConnectionPool::threadConnection().registerService( QLatin1String( "org.freedesktop.Akonadi.MailDispatcherAgent" ) );
KDBusConnectionPool::threadConnection().registerService( QLatin1String( "org.freedesktop.Akonadi.MailDispatcherAgent" ) );
d->queue = new OutboxQueue( this );
connect( d->queue, SIGNAL(newItems()),
......
......@@ -24,7 +24,7 @@
#include <agentinstance.h>
#include <agentmanager.h>
#include <collection.h>
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <item.h>
#include <itemdeletejob.h>
#include <itemmodifyjob.h>
......@@ -144,7 +144,7 @@ void SendJob::Private::doAkonadiTransport()
interface = new QDBusInterface(
QLatin1String( "org.freedesktop.Akonadi.Resource." ) + resourceId,
QLatin1String( "/Transport" ), QLatin1String( "org.freedesktop.Akonadi.Resource.Transport" ),
DBusConnectionPool::threadConnection(), q );
KDBusConnectionPool::threadConnection(), q );
if ( !interface->isValid() ) {
storeResult( false, i18n( "Failed to get D-Bus interface of resource %1.", resourceId ) );
......@@ -324,7 +324,7 @@ bool SendJob::Private::filterItem( int filterset )
mailfilterInterface = new QDBusInterface(
QLatin1String( "org.freedesktop.Akonadi.MailFilterAgent" ),
QLatin1String( "/MailFilterAgent" ), QLatin1String( "org.freedesktop.Akonadi.MailFilterAgent" ),
DBusConnectionPool::threadConnection(), q );
KDBusConnectionPool::threadConnection(), q );
if ( !mailfilterInterface->isValid() ) {
......
......@@ -31,7 +31,7 @@
#include <KIdentityManagement/IdentityManager>
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <agentfactory.h>
#include <changerecorder.h>
......@@ -69,9 +69,9 @@ NewMailNotifierAgent::NewMailNotifierAgent( const QString &id )
connect(mIdentityManager, SIGNAL(changed()), SLOT(slotIdentitiesChanged()));
slotIdentitiesChanged();
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/NewMailNotifierAgent" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/NewMailNotifierAgent" ),
this, QDBusConnection::ExportAdaptors );
DBusConnectionPool::threadConnection().registerService( QLatin1String( "org.freedesktop.Akonadi.NewMailNotifierAgent" ) );
KDBusConnectionPool::threadConnection().registerService( QLatin1String( "org.freedesktop.Akonadi.NewMailNotifierAgent" ) );
connect(Akonadi::AgentManager::self(), &Akonadi::AgentManager::instanceStatusChanged, this, &NewMailNotifierAgent::slotInstanceStatusChanged);
connect(Akonadi::AgentManager::self(), &Akonadi::AgentManager::instanceRemoved, this, &NewMailNotifierAgent::slotInstanceRemoved);
......
......@@ -4,7 +4,7 @@ add_definitions( -DQT_NO_CAST_TO_ASCII )
if ("${CMAKE_SOURCE_DIR}" STREQUAL "${kcmakonadi_SOURCE_DIR}")
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
find_package(KF5KCMUtils ${KF5_VERSION} CONFIG REQUIRED)
find_package(KF5Akonadi ${KDEPIMLIBS_LIB_VERSION} CONFIG REQUIRED)
endif()
......
......@@ -13,7 +13,7 @@ find_package(ECM 1.3.0 CONFIG REQUIRED)
include(KDECMakeSettings)
include(KDEFrameworkCompilerSettings)
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
set(KF5_VERSION "5.4.0")
set(QT_REQUIRED_VERSION "5.3.0")
......
......@@ -11,7 +11,7 @@ if ("${CMAKE_SOURCE_DIR}" STREQUAL "${migration_SOURCE_DIR}")
include(KDEInstallDirs)
include(KDECMakeSettings)
include(KDEFrameworkCompilerSettings)
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
set(KF5_VERSION "5.4.0")
set(QT_REQUIRED_VERSION "5.3.0")
......
......@@ -12,7 +12,7 @@ include_directories(
if ("${CMAKE_SOURCE_DIR}" STREQUAL "${plugins_SOURCE_DIR}")
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
find_package(Qt5DBus ${KF5_VERSION} CONFIG REQUIRED)
find_package(KF5KDELibs4Support ${KF5_VERSION} CONFIG REQUIRED)
find_package(KF5Akonadi ${KDEPIMLIBS_LIB_VERSION} CONFIG REQUIRED)
......
......@@ -16,7 +16,7 @@ if ("${CMAKE_SOURCE_DIR}" STREQUAL "${resources_SOURCE_DIR}")
set(KF5_VERSION "5.4.0")
set(QT_REQUIRED_VERSION "5.3.0")
set(KDEPIMLIBS_LIB_VERSION "4.72.0")
set(KDEPIMLIBS_LIB_VERSION "4.73.0")
set(KDEPIM_LIB_VERSION "4.70.0")
set(KDEPIM_LIB_SOVERSION "5")
......
......@@ -31,7 +31,7 @@
#include <collectionfetchscope.h>
#include <entitydisplayattribute.h>
#include <itemfetchscope.h>
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <agentfactory.h>
#include <QDebug>
......@@ -46,7 +46,7 @@ ContactsResource::ContactsResource( const QString &id )
{
// setup the resource
new ContactsResourceSettingsAdaptor( mSettings );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
mSettings, QDBusConnection::ExportAdaptors );
changeRecorder()->fetchCollection( true );
......
......@@ -22,7 +22,7 @@
#include "icalsettingsadaptor.h"
#include "singlefileresourceconfigdialog.h"
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <KCalCore/FileStorage>
#include <KCalCore/MemoryCalendar>
......@@ -45,7 +45,7 @@ void ICalResourceBase::initialise( const QStringList &mimeTypes, const QString &
{
setSupportedMimetypes( mimeTypes, icon );
new ICalSettingsAdaptor( mSettings );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
mSettings, QDBusConnection::ExportAdaptors );
}
......
......@@ -34,7 +34,7 @@
#include <KCalCore/MemoryCalendar>
#include <agentfactory.h>
#include <changerecorder.h>
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <entitydisplayattribute.h>
#include <collectionfetchjob.h>
#include <collectionfetchscope.h>
......@@ -83,7 +83,7 @@ KAlarmDirResource::KAlarmDirResource(const QString& id)
// Set up the resource
new KAlarmDirSettingsAdaptor(mSettings);
DBusConnectionPool::threadConnection().registerObject(QLatin1String("/Settings"),
KDBusConnectionPool::threadConnection().registerObject(QLatin1String("/Settings"),
mSettings, QDBusConnection::ExportAdaptors);
connect(mSettings, &Akonadi_KAlarm_Dir_Resource::Settings::configChanged, this, &KAlarmDirResource::settingsChanged);
......
......@@ -22,7 +22,7 @@
#include "settingsadaptor.h"
#include "singlefileresourceconfigdialog.h"
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <KLocalizedString>
#include <QIcon>
......@@ -37,7 +37,7 @@ KDEAccountsResource::KDEAccountsResource( const QString &id )
setName( i18n( "KDE Accounts" ) );
new SettingsAdaptor( mSettings );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
mSettings, QDBusConnection::ExportAdaptors );
}
......
......@@ -34,7 +34,7 @@
#include <collectionfetchscope.h>
#include <cachepolicy.h>
#include <collectionfetchjob.h>
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <kmime/kmime_message.h>
......@@ -113,7 +113,7 @@ MaildirResource::MaildirResource( const QString &id )
job->start();
}
new MaildirSettingsAdaptor( mSettings );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
mSettings, QDBusConnection::ExportAdaptors );
connect(this, &MaildirResource::reloadConfiguration, this, &MaildirResource::configurationChanged);
......
......@@ -26,7 +26,7 @@
#include <changerecorder.h>
#include <collectionfetchjob.h>
#include <collectionmodifyjob.h>
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <itemfetchscope.h>
#include <kmbox/mbox.h>
#include <kmime/kmime_message.h>
......@@ -67,7 +67,7 @@ MboxResource::MboxResource( const QString &id )
, mMBox( 0 )
{
new SettingsAdaptor( mSettings );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
mSettings, QDBusConnection::ExportAdaptors );
QStringList mimeTypes;
......
......@@ -22,7 +22,7 @@
#include "vcardsettingsadaptor.h"
#include "singlefileresourceconfigdialog.h"
#include <dbusconnectionpool.h>
#include <kdbusconnectionpool.h>
#include <agentfactory.h>
#include <KLocalizedString>
......@@ -38,7 +38,7 @@ VCardResource::VCardResource( const QString &id )
setSupportedMimetypes( QStringList() << KABC::Addressee::mimeType(), QLatin1String("office-address-book") );
new VCardSettingsAdaptor( mSettings );
DBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
KDBusConnectionPool::threadConnection().registerObject( QLatin1String( "/Settings" ),
mSettings, QDBusConnection::ExportAdaptors );
}
......
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