author | alwin <alwin> | 2003-12-28 02:45:07 (UTC) |
---|---|---|
committer | alwin <alwin> | 2003-12-28 02:45:07 (UTC) |
commit | d1a7eb08cad465c5fc0de53f75aaecf7803f0945 (patch) (side-by-side diff) | |
tree | 422b73af760cdd44e4fbbc96bd6876a15939ff19 /noncore/net/mail/pop3wrapper.cpp | |
parent | e889485e945d8fa9564566f286114be10d2a1ce5 (diff) | |
download | opie-d1a7eb08cad465c5fc0de53f75aaecf7803f0945.zip opie-d1a7eb08cad465c5fc0de53f75aaecf7803f0945.tar.gz opie-d1a7eb08cad465c5fc0de53f75aaecf7803f0945.tar.bz2 |
- dir handling for mbox accounts (delete, new, delete all mail)
- fixed memory leaks in mbox account class
- reduced count of used string constants while using "tr" with context string
- mbox displays messages into global status bar
- fixed a possible raise condition when deleting a mail directory
Diffstat (limited to 'noncore/net/mail/pop3wrapper.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/net/mail/pop3wrapper.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/noncore/net/mail/pop3wrapper.cpp b/noncore/net/mail/pop3wrapper.cpp index efd83ba..b85fbf6 100644 --- a/noncore/net/mail/pop3wrapper.cpp +++ b/noncore/net/mail/pop3wrapper.cpp @@ -1,13 +1,12 @@ #include <stdlib.h> #include "pop3wrapper.h" #include "mailtypes.h" #include "logindialog.h" -#include <libetpan/mailpop3.h> -#include <libetpan/mailmime.h> -#include <libetpan/data_message_driver.h> +#include <libetpan/libetpan.h> +#include <qpe/global.h> #include <qfile.h> /* we don't fetch messages larger than 5 MB */ #define HARD_MSG_SIZE_LIMIT 5242880 POP3wrapper::POP3wrapper( POP3account *a ) @@ -109,12 +108,13 @@ void POP3wrapper::listMessages(const QString &, QList<RecMail> &target ) /* these vars are used recurcive! set it to 0!!!!!!!!!!!!!!!!! */ size_t length = 0; carray * messages = 0; login(); if (!m_pop3) return; + mailpop3_list( m_pop3, &messages ); for (unsigned int i = 0; i < carray_count(messages);++i) { mailpop3_msg_info *info; err = mailpop3_get_msg_info(m_pop3,i+1,&info); if (info->msg_deleted) @@ -129,12 +129,13 @@ void POP3wrapper::listMessages(const QString &, QList<RecMail> &target ) mail->setNumber( info->msg_index ); mail->setWrapper(this); mail->setMsgsize(info->msg_size); target.append( mail ); free(header); } + Global::statusMessage( tr("Mailbox contains %1 mail(s)").arg(carray_count(messages)-m_pop3->pop3_deleted_count)); } void POP3wrapper::login() { /* we'll hold the line */ if ( m_pop3 != NULL ) return; |