author | alwin <alwin> | 2003-12-23 20:31:24 (UTC) |
---|---|---|
committer | alwin <alwin> | 2003-12-23 20:31:24 (UTC) |
commit | 7c720aabcad9b325dbf9910493e3c9fa1d63805e (patch) (unidiff) | |
tree | a6a7cbc34070c14f2b8b202c1850b57564e836b2 /noncore | |
parent | 0a613593f2e57c2805d1eef47c16b9fcb8c94a08 (diff) | |
download | opie-7c720aabcad9b325dbf9910493e3c9fa1d63805e.zip opie-7c720aabcad9b325dbf9910493e3c9fa1d63805e.tar.gz opie-7c720aabcad9b325dbf9910493e3c9fa1d63805e.tar.bz2 |
resolved a name conflict
-rw-r--r-- | noncore/net/mail/imapwrapper.cpp | 23 | ||||
-rw-r--r-- | noncore/net/mail/libmailwrapper/imapwrapper.cpp | 23 |
2 files changed, 22 insertions, 24 deletions
diff --git a/noncore/net/mail/imapwrapper.cpp b/noncore/net/mail/imapwrapper.cpp index 30eb678..853e4a2 100644 --- a/noncore/net/mail/imapwrapper.cpp +++ b/noncore/net/mail/imapwrapper.cpp | |||
@@ -1,7 +1,7 @@ | |||
1 | 1 | ||
2 | #include <stdlib.h> | 2 | #include <stdlib.h> |
3 | 3 | ||
4 | #include <libetpan/mailimap.h> | 4 | #include <libetpan/libetpan.h> |
5 | 5 | ||
6 | #include "imapwrapper.h" | 6 | #include "imapwrapper.h" |
7 | #include "mailtypes.h" | 7 | #include "mailtypes.h" |
@@ -322,8 +322,7 @@ RecMail*IMAPwrapper::parse_list_result(mailimap_msg_att* m_att) | |||
322 | } | 322 | } |
323 | m->setMsgid(QString(head->env_message_id)); | 323 | m->setMsgid(QString(head->env_message_id)); |
324 | } else if (item->att_data.att_static->att_type==MAILIMAP_MSG_ATT_INTERNALDATE) { | 324 | } else if (item->att_data.att_static->att_type==MAILIMAP_MSG_ATT_INTERNALDATE) { |
325 | #if 0 | 325 | #if 0 |
326 | |||
327 | mailimap_date_time*d = item->att_data.att_static->att_data.att_internal_date; | 326 | mailimap_date_time*d = item->att_data.att_static->att_data.att_internal_date; |
328 | QDateTime da(QDate(d->dt_year,d->dt_month,d->dt_day),QTime(d->dt_hour,d->dt_min,d->dt_sec)); | 327 | QDateTime da(QDate(d->dt_year,d->dt_month,d->dt_day),QTime(d->dt_hour,d->dt_min,d->dt_sec)); |
329 | qDebug("%i %i %i - %i %i %i",d->dt_year,d->dt_month,d->dt_day,d->dt_hour,d->dt_min,d->dt_sec); | 328 | qDebug("%i %i %i - %i %i %i",d->dt_year,d->dt_month,d->dt_day,d->dt_hour,d->dt_min,d->dt_sec); |
@@ -554,28 +553,28 @@ void IMAPwrapper::searchBodyText(const RecMail&mail,mailimap_body_type_mpart*mai | |||
554 | ++count; | 553 | ++count; |
555 | current_body = (mailimap_body*)current->data; | 554 | current_body = (mailimap_body*)current->data; |
556 | if (current_body->bd_type==MAILIMAP_BODY_MPART) { | 555 | if (current_body->bd_type==MAILIMAP_BODY_MPART) { |
557 | QValueList<int>clist = recList; | 556 | QValueList<int>countlist = recList; |
558 | clist.append(count); | 557 | countlist.append(count); |
559 | searchBodyText(mail,current_body->bd_data.bd_body_mpart,target_body,current_recursion+1,clist); | 558 | searchBodyText(mail,current_body->bd_data.bd_body_mpart,target_body,current_recursion+1,countlist); |
560 | } else if (current_body->bd_type==MAILIMAP_BODY_1PART){ | 559 | } else if (current_body->bd_type==MAILIMAP_BODY_1PART){ |
561 | RecPart currentPart; | 560 | RecPart currentPart; |
562 | fillSinglePart(currentPart,current_body->bd_data.bd_body_1part); | 561 | fillSinglePart(currentPart,current_body->bd_data.bd_body_1part); |
563 | QValueList<int>clist = recList; | 562 | QValueList<int>countlist = recList; |
564 | clist.append(count); | 563 | countlist.append(count); |
565 | /* important: Check for is NULL 'cause a body can be empty! */ | 564 | /* important: Check for is NULL 'cause a body can be empty! */ |
566 | if (currentPart.Type()=="text" && target_body.Bodytext().isNull() ) { | 565 | if (currentPart.Type()=="text" && target_body.Bodytext().isNull() ) { |
567 | QString body_text = fetchTextPart(mail,clist,true,currentPart.Encoding()); | 566 | QString body_text = fetchTextPart(mail,countlist,true,currentPart.Encoding()); |
568 | target_body.setDescription(currentPart); | 567 | target_body.setDescription(currentPart); |
569 | target_body.setBodytext(body_text); | 568 | target_body.setBodytext(body_text); |
570 | } else { | 569 | } else { |
571 | QString id(""); | 570 | QString id(""); |
572 | for (unsigned int j = 0; j < clist.count();++j) { | 571 | for (unsigned int j = 0; j < countlist.count();++j) { |
573 | id+=(j>0?" ":""); | 572 | id+=(j>0?" ":""); |
574 | id+=QString("%1").arg(clist[j]); | 573 | id+=QString("%1").arg(countlist[j]); |
575 | } | 574 | } |
576 | qDebug("ID= %s",id.latin1()); | 575 | qDebug("ID= %s",id.latin1()); |
577 | currentPart.setIdentifier(id); | 576 | currentPart.setIdentifier(id); |
578 | currentPart.setPositionlist(clist); | 577 | currentPart.setPositionlist(countlist); |
579 | target_body.addPart(currentPart); | 578 | target_body.addPart(currentPart); |
580 | } | 579 | } |
581 | } | 580 | } |
diff --git a/noncore/net/mail/libmailwrapper/imapwrapper.cpp b/noncore/net/mail/libmailwrapper/imapwrapper.cpp index 30eb678..853e4a2 100644 --- a/noncore/net/mail/libmailwrapper/imapwrapper.cpp +++ b/noncore/net/mail/libmailwrapper/imapwrapper.cpp | |||
@@ -1,7 +1,7 @@ | |||
1 | 1 | ||
2 | #include <stdlib.h> | 2 | #include <stdlib.h> |
3 | 3 | ||
4 | #include <libetpan/mailimap.h> | 4 | #include <libetpan/libetpan.h> |
5 | 5 | ||
6 | #include "imapwrapper.h" | 6 | #include "imapwrapper.h" |
7 | #include "mailtypes.h" | 7 | #include "mailtypes.h" |
@@ -322,8 +322,7 @@ RecMail*IMAPwrapper::parse_list_result(mailimap_msg_att* m_att) | |||
322 | } | 322 | } |
323 | m->setMsgid(QString(head->env_message_id)); | 323 | m->setMsgid(QString(head->env_message_id)); |
324 | } else if (item->att_data.att_static->att_type==MAILIMAP_MSG_ATT_INTERNALDATE) { | 324 | } else if (item->att_data.att_static->att_type==MAILIMAP_MSG_ATT_INTERNALDATE) { |
325 | #if 0 | 325 | #if 0 |
326 | |||
327 | mailimap_date_time*d = item->att_data.att_static->att_data.att_internal_date; | 326 | mailimap_date_time*d = item->att_data.att_static->att_data.att_internal_date; |
328 | QDateTime da(QDate(d->dt_year,d->dt_month,d->dt_day),QTime(d->dt_hour,d->dt_min,d->dt_sec)); | 327 | QDateTime da(QDate(d->dt_year,d->dt_month,d->dt_day),QTime(d->dt_hour,d->dt_min,d->dt_sec)); |
329 | qDebug("%i %i %i - %i %i %i",d->dt_year,d->dt_month,d->dt_day,d->dt_hour,d->dt_min,d->dt_sec); | 328 | qDebug("%i %i %i - %i %i %i",d->dt_year,d->dt_month,d->dt_day,d->dt_hour,d->dt_min,d->dt_sec); |
@@ -554,28 +553,28 @@ void IMAPwrapper::searchBodyText(const RecMail&mail,mailimap_body_type_mpart*mai | |||
554 | ++count; | 553 | ++count; |
555 | current_body = (mailimap_body*)current->data; | 554 | current_body = (mailimap_body*)current->data; |
556 | if (current_body->bd_type==MAILIMAP_BODY_MPART) { | 555 | if (current_body->bd_type==MAILIMAP_BODY_MPART) { |
557 | QValueList<int>clist = recList; | 556 | QValueList<int>countlist = recList; |
558 | clist.append(count); | 557 | countlist.append(count); |
559 | searchBodyText(mail,current_body->bd_data.bd_body_mpart,target_body,current_recursion+1,clist); | 558 | searchBodyText(mail,current_body->bd_data.bd_body_mpart,target_body,current_recursion+1,countlist); |
560 | } else if (current_body->bd_type==MAILIMAP_BODY_1PART){ | 559 | } else if (current_body->bd_type==MAILIMAP_BODY_1PART){ |
561 | RecPart currentPart; | 560 | RecPart currentPart; |
562 | fillSinglePart(currentPart,current_body->bd_data.bd_body_1part); | 561 | fillSinglePart(currentPart,current_body->bd_data.bd_body_1part); |
563 | QValueList<int>clist = recList; | 562 | QValueList<int>countlist = recList; |
564 | clist.append(count); | 563 | countlist.append(count); |
565 | /* important: Check for is NULL 'cause a body can be empty! */ | 564 | /* important: Check for is NULL 'cause a body can be empty! */ |
566 | if (currentPart.Type()=="text" && target_body.Bodytext().isNull() ) { | 565 | if (currentPart.Type()=="text" && target_body.Bodytext().isNull() ) { |
567 | QString body_text = fetchTextPart(mail,clist,true,currentPart.Encoding()); | 566 | QString body_text = fetchTextPart(mail,countlist,true,currentPart.Encoding()); |
568 | target_body.setDescription(currentPart); | 567 | target_body.setDescription(currentPart); |
569 | target_body.setBodytext(body_text); | 568 | target_body.setBodytext(body_text); |
570 | } else { | 569 | } else { |
571 | QString id(""); | 570 | QString id(""); |
572 | for (unsigned int j = 0; j < clist.count();++j) { | 571 | for (unsigned int j = 0; j < countlist.count();++j) { |
573 | id+=(j>0?" ":""); | 572 | id+=(j>0?" ":""); |
574 | id+=QString("%1").arg(clist[j]); | 573 | id+=QString("%1").arg(countlist[j]); |
575 | } | 574 | } |
576 | qDebug("ID= %s",id.latin1()); | 575 | qDebug("ID= %s",id.latin1()); |
577 | currentPart.setIdentifier(id); | 576 | currentPart.setIdentifier(id); |
578 | currentPart.setPositionlist(clist); | 577 | currentPart.setPositionlist(countlist); |
579 | target_body.addPart(currentPart); | 578 | target_body.addPart(currentPart); |
580 | } | 579 | } |
581 | } | 580 | } |