Diffstat (limited to 'noncore/net/mail/accountitem.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/net/mail/accountitem.cpp | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/noncore/net/mail/accountitem.cpp b/noncore/net/mail/accountitem.cpp index 0d636a4..396dcb7 100644 --- a/noncore/net/mail/accountitem.cpp +++ b/noncore/net/mail/accountitem.cpp | |||
@@ -904,27 +904,27 @@ void MHfolderItem::initName() | |||
904 | int pos = bName.findRev("/"); | 904 | int pos = bName.findRev("/"); |
905 | if (pos > 0) | 905 | if (pos > 0) |
906 | { | 906 | { |
907 | bName.replace(0,pos+1,""); | 907 | bName.replace(0,pos+1,""); |
908 | } | 908 | } |
909 | if (bName.lower() == "outgoing") | 909 | if (bName.lower() == "outgoing") |
910 | { | 910 | { |
911 | setPixmap( 0, PIXMAP_OUTBOXFOLDER ); | 911 | setPixmap( 0, PIXMAP_OUTBOXFOLDER ); |
912 | } | 912 | } |
913 | else if (bName.lower() == "inbox") | 913 | else if (bName.lower() == "inbox") |
914 | { | 914 | { |
915 | setPixmap( 0, PIXMAP_INBOXFOLDER); | 915 | setPixmap( 0, PIXMAP_INBOXFOLDER); |
916 | } | 916 | } else if (bName.lower() == "drafts") { |
917 | else | 917 | setPixmap(0, Resource::loadPixmap("inline/edit")); |
918 | { | 918 | } else { |
919 | setPixmap( 0, PIXMAP_MBOXFOLDER ); | 919 | setPixmap( 0, PIXMAP_MBOXFOLDER ); |
920 | } | 920 | } |
921 | setText( 0, bName ); | 921 | setText( 0, bName ); |
922 | } | 922 | } |
923 | 923 | ||
924 | Folder*MHfolderItem::getFolder() | 924 | Folder*MHfolderItem::getFolder() |
925 | { | 925 | { |
926 | return folder; | 926 | return folder; |
927 | } | 927 | } |
928 | 928 | ||
929 | void MHfolderItem::refresh(QList<RecMail>&target) | 929 | void MHfolderItem::refresh(QList<RecMail>&target) |
930 | { | 930 | { |
@@ -1014,24 +1014,30 @@ void MHfolderItem::contextMenuSelected(int which) | |||
1014 | break; | 1014 | break; |
1015 | case 2: | 1015 | case 2: |
1016 | downloadMails(); | 1016 | downloadMails(); |
1017 | break; | 1017 | break; |
1018 | case 3: | 1018 | case 3: |
1019 | createFolder(); | 1019 | createFolder(); |
1020 | break; | 1020 | break; |
1021 | default: | 1021 | default: |
1022 | break; | 1022 | break; |
1023 | } | 1023 | } |
1024 | } | 1024 | } |
1025 | 1025 | ||
1026 | bool MHfolderItem::isDraftfolder() | ||
1027 | { | ||
1028 | if (folder && folder->getName()==AbstractMail::defaultLocalfolder()+"/"+AbstractMail::draftFolder()) return true; | ||
1029 | return false; | ||
1030 | } | ||
1031 | |||
1026 | /** | 1032 | /** |
1027 | * Generic stuff | 1033 | * Generic stuff |
1028 | */ | 1034 | */ |
1029 | 1035 | ||
1030 | const QString AccountViewItem::contextName="AccountViewItem"; | 1036 | const QString AccountViewItem::contextName="AccountViewItem"; |
1031 | 1037 | ||
1032 | AccountViewItem::AccountViewItem( AccountView *parent ) | 1038 | AccountViewItem::AccountViewItem( AccountView *parent ) |
1033 | : QListViewItem( parent ) | 1039 | : QListViewItem( parent ) |
1034 | { | 1040 | { |
1035 | init(); | 1041 | init(); |
1036 | m_Backlink = parent; | 1042 | m_Backlink = parent; |
1037 | } | 1043 | } |
@@ -1118,12 +1124,17 @@ AccountViewItem*AccountViewItem::findSubItem(const QString&path,AccountViewItem* | |||
1118 | { | 1124 | { |
1119 | sitem = findSubItem(path,pitem); | 1125 | sitem = findSubItem(path,pitem); |
1120 | if (sitem) | 1126 | if (sitem) |
1121 | { | 1127 | { |
1122 | pitem = sitem; | 1128 | pitem = sitem; |
1123 | break; | 1129 | break; |
1124 | } | 1130 | } |
1125 | } | 1131 | } |
1126 | pitem=(AccountViewItem*)pitem->nextSibling(); | 1132 | pitem=(AccountViewItem*)pitem->nextSibling(); |
1127 | } | 1133 | } |
1128 | return pitem; | 1134 | return pitem; |
1129 | } | 1135 | } |
1136 | |||
1137 | bool AccountViewItem::isDraftfolder() | ||
1138 | { | ||
1139 | return false; | ||
1140 | } | ||