summaryrefslogtreecommitdiff
path: root/noncore/unsupported/mailit/emailhandler.cpp
Unidiff
Diffstat (limited to 'noncore/unsupported/mailit/emailhandler.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/unsupported/mailit/emailhandler.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/noncore/unsupported/mailit/emailhandler.cpp b/noncore/unsupported/mailit/emailhandler.cpp
index fbbada7..c7b27a0 100644
--- a/noncore/unsupported/mailit/emailhandler.cpp
+++ b/noncore/unsupported/mailit/emailhandler.cpp
@@ -36,12 +36,14 @@ Enclosure* EnclosureList::dupl(Enclosure *in)
36 ac = new Enclosure(*in); 36 ac = new Enclosure(*in);
37 return ac; 37 return ac;
38} 38}
39 39
40EmailHandler::EmailHandler() 40EmailHandler::EmailHandler()
41{ 41{
42 qDebug("EMailHandler::EmailHandler");
43
42 smtpClient = new SmtpClient(); 44 smtpClient = new SmtpClient();
43 popClient = new PopClient(); 45 popClient = new PopClient();
44 46
45 connect(smtpClient, SIGNAL(errorOccurred(int)), this, 47 connect(smtpClient, SIGNAL(errorOccurred(int)), this,
46 SIGNAL(smtpError(int)) ); 48 SIGNAL(smtpError(int)) );
47 connect(smtpClient, SIGNAL(mailSent()), this, SIGNAL(mailSent()) ); 49 connect(smtpClient, SIGNAL(mailSent()), this, SIGNAL(mailSent()) );
@@ -112,12 +114,13 @@ void EmailHandler::getMailHeaders()
112{ 114{
113 popClient->setAccount(mailAccount.popUserName, mailAccount.popPasswd); 115 popClient->setAccount(mailAccount.popUserName, mailAccount.popPasswd);
114 mailAccount.synchronize ? popClient->setSynchronize(mailAccount.lastServerMailCount): popClient->removeSynchronize(); 116 mailAccount.synchronize ? popClient->setSynchronize(mailAccount.lastServerMailCount): popClient->removeSynchronize();
115 117
116 headers = TRUE; 118 headers = TRUE;
117 popClient->headersOnly(headers, mailAccount.syncLimit); //less than requested syncLimit, download all 119 popClient->headersOnly(headers, mailAccount.syncLimit); //less than requested syncLimit, download all
120 qDebug("Initiating connection");
118 popClient->newConnection(mailAccount.popServer, 110); 121 popClient->newConnection(mailAccount.popServer, 110);
119} 122}
120 123
121void EmailHandler::getMailByList(MailList *mailList) 124void EmailHandler::getMailByList(MailList *mailList)
122{ 125{
123 if (mailList->count() == 0) { //should not occur though 126 if (mailList->count() == 0) { //should not occur though
@@ -623,6 +626,7 @@ void EmailHandler::encode64base(char *src, QString *dest, int len)
623 626
624void EmailHandler::cancel() 627void EmailHandler::cancel()
625{ 628{
626 popClient->errorHandling(ErrCancel); 629 popClient->errorHandling(ErrCancel);
627 smtpClient->errorHandling(ErrCancel); 630 smtpClient->errorHandling(ErrCancel);
628} 631}
632