summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Mollekopf <mollekopf@kolabsys.com>2013-11-04 08:09:05 (GMT)
committerChristian Mollekopf <mollekopf@kolabsys.com>2013-11-04 08:09:05 (GMT)
commitd630aa098fdc1fff945c843f19b705c5af0af9dd (patch)
tree84091276e8ea923ad82a2b184cbb96fa8d1c0770
parent0890a67383f6134270549cb1f64f7a4823aacc8a (diff)
downloadkolab-utils-d630aa098fdc1fff945c843f19b705c5af0af9dd.tar.gz
enabled google mail migration.
-rw-r--r--migrationutility/googlesourceserver.cpp11
-rw-r--r--migrationutility/googlesourceserver.h3
2 files changed, 6 insertions, 8 deletions
diff --git a/migrationutility/googlesourceserver.cpp b/migrationutility/googlesourceserver.cpp
index 6c07226..6301b3b 100644
--- a/migrationutility/googlesourceserver.cpp
+++ b/migrationutility/googlesourceserver.cpp
@@ -25,8 +25,6 @@
#include <commonconversion.h>
#include <errorhandler.h>
-#include "sessionfactory.h"
-
GoogleSourceServer::GoogleSourceServer(QObject* parent)
: SourceServer(parent),
mEncryptionMode(KIMAP::LoginJob::TlsV1),
@@ -57,7 +55,7 @@ void GoogleSourceServer::setAuthentication(KIMAP::LoginJob::AuthenticationMode a
mAuthenticationMode = auth;
}
-QList<SourceAccount*> GoogleSourceServer::getSourceAccounts(const QString& user)
+QList<SourceAccount*> GoogleSourceServer::getSourceAccountsImpl(const QString& user)
{
QList <SourceAccount*> sourceAccounts;
@@ -69,8 +67,9 @@ QList<SourceAccount*> GoogleSourceServer::getSourceAccounts(const QString& user)
calendarAccount->setUser(user);
sourceAccounts << calendarAccount;
-// IMAPSourceAccount *imapAccount = new IMAPSourceAccount(this);
-// imapAccount->prepareConnection(mHost, mPort, user, user, mPw, mEncryptionMode, mAuthenticationMode);
-// sourceAccounts << imapAccount;
+ IMAPSourceAccount *imapAccount = new IMAPSourceAccount(this);
+ imapAccount->prepareConnection(mHost, mPort, user, user, mPw, mEncryptionMode, mAuthenticationMode);
+ sourceAccounts << imapAccount;
+
return sourceAccounts;
} \ No newline at end of file
diff --git a/migrationutility/googlesourceserver.h b/migrationutility/googlesourceserver.h
index 63ac4df..2af8f04 100644
--- a/migrationutility/googlesourceserver.h
+++ b/migrationutility/googlesourceserver.h
@@ -29,13 +29,12 @@ class GoogleSourceServer: public SourceServer
public:
explicit GoogleSourceServer(QObject* parent = 0);
- virtual QList<SourceAccount*> getSourceAccounts(const QString& user);
-
void setHost(const QString &host, qint16 port);
void setAdminCredentials(const QString &username, const QString &pw);
void setEncryption(KIMAP::LoginJob::EncryptionMode);
void setAuthentication(KIMAP::LoginJob::AuthenticationMode);
protected:
+ virtual QList<SourceAccount*> getSourceAccountsImpl(const QString& user);
void logout();
QString mHost;
int mPort;