From a4b557ded81814ed528acdf3b079064988321162 Mon Sep 17 00:00:00 2001 From: Montel Laurent Date: Sat, 3 Jan 2015 08:48:29 +0100 Subject: [PATCH 1/2] Use imapresourcemanager --- kmkernel.cpp | 7 +++++++ kmkernel.h | 3 +++ 2 files changed, 10 insertions(+) diff --git a/kmkernel.cpp b/kmkernel.cpp index 4d631c455..2195e35b8 100644 --- a/kmkernel.cpp +++ b/kmkernel.cpp @@ -114,6 +114,7 @@ using KMail::MailServiceImpl; #include "foldercollectionmonitor.h" #include "imapresourcesettings.h" #include "util.h" +#include "pimcommon/util/imapresourcemanager.h" #include "mailcommon/kernel/mailkernel.h" #include "searchdialog/searchdescriptionattribute.h" @@ -143,6 +144,7 @@ KMKernel::KMKernel (QObject *parent) : KMail::Util::migrateFromKMail1(); kDebug() << "Starting up..."; + mImapResourceManager = new PimCommon::ImapResourceManager(this); mySelf = this; the_firstInstance = true; @@ -2082,6 +2084,11 @@ PimCommon::StorageServiceManager *KMKernel::storageServiceManager() const return mStorageManager; } +PimCommon::ImapResourceManager *KMKernel::imapResourceManager() const +{ + return mImapResourceManager; +} + bool KMKernel::allowToDebugBalooSupport() const { return mDebugBaloo; diff --git a/kmkernel.h b/kmkernel.h index 1c66223eb..aa4c61116 100644 --- a/kmkernel.h +++ b/kmkernel.h @@ -44,6 +44,7 @@ class MessageSender; namespace PimCommon { class AutoCorrection; class StorageServiceManager; +class ImapResourceManager; } /** The KMail namespace contains classes used for KMail. @@ -426,6 +427,7 @@ public: void toggleSystemTray(); FolderArchiveManager *folderArchiveManager() const; PimCommon::StorageServiceManager *storageServiceManager() const; + PimCommon::ImapResourceManager *imapResourceManager() const; bool allowToDebugBalooSupport() const; @@ -533,6 +535,7 @@ private: PimCommon::AutoCorrection *mAutoCorrection; FolderArchiveManager *mFolderArchiveManager; PimCommon::StorageServiceManager *mStorageManager; + PimCommon::ImapResourceManager *mImapResourceManager; bool mDebugBaloo; }; From abd9f2466548a585e5312b0053b58e4f6442e715 Mon Sep 17 00:00:00 2001 From: Montel Laurent Date: Sat, 3 Jan 2015 09:03:18 +0100 Subject: [PATCH 2/2] Better to move this code to mailkernel directly --- kmkernel.cpp | 7 ------- kmkernel.h | 3 --- 2 files changed, 10 deletions(-) diff --git a/kmkernel.cpp b/kmkernel.cpp index 2195e35b8..4d631c455 100644 --- a/kmkernel.cpp +++ b/kmkernel.cpp @@ -114,7 +114,6 @@ using KMail::MailServiceImpl; #include "foldercollectionmonitor.h" #include "imapresourcesettings.h" #include "util.h" -#include "pimcommon/util/imapresourcemanager.h" #include "mailcommon/kernel/mailkernel.h" #include "searchdialog/searchdescriptionattribute.h" @@ -144,7 +143,6 @@ KMKernel::KMKernel (QObject *parent) : KMail::Util::migrateFromKMail1(); kDebug() << "Starting up..."; - mImapResourceManager = new PimCommon::ImapResourceManager(this); mySelf = this; the_firstInstance = true; @@ -2084,11 +2082,6 @@ PimCommon::StorageServiceManager *KMKernel::storageServiceManager() const return mStorageManager; } -PimCommon::ImapResourceManager *KMKernel::imapResourceManager() const -{ - return mImapResourceManager; -} - bool KMKernel::allowToDebugBalooSupport() const { return mDebugBaloo; diff --git a/kmkernel.h b/kmkernel.h index aa4c61116..1c66223eb 100644 --- a/kmkernel.h +++ b/kmkernel.h @@ -44,7 +44,6 @@ class MessageSender; namespace PimCommon { class AutoCorrection; class StorageServiceManager; -class ImapResourceManager; } /** The KMail namespace contains classes used for KMail. @@ -427,7 +426,6 @@ public: void toggleSystemTray(); FolderArchiveManager *folderArchiveManager() const; PimCommon::StorageServiceManager *storageServiceManager() const; - PimCommon::ImapResourceManager *imapResourceManager() const; bool allowToDebugBalooSupport() const; @@ -535,7 +533,6 @@ private: PimCommon::AutoCorrection *mAutoCorrection; FolderArchiveManager *mFolderArchiveManager; PimCommon::StorageServiceManager *mStorageManager; - PimCommon::ImapResourceManager *mImapResourceManager; bool mDebugBaloo; };