summaryrefslogtreecommitdiffabout
path: root/kmicromail/accountview.cpp
authorzautrix <zautrix>2004-09-11 08:56:57 (UTC)
committer zautrix <zautrix>2004-09-11 08:56:57 (UTC)
commit0f45c977d7530b6ca827b7a7c7da7469f01800ca (patch) (side-by-side diff)
tree0368bbd4865a0b21bb197cfd0a190fd0c2cd9242 /kmicromail/accountview.cpp
parent1b41a0e3bf63364940daf132446939e3570c57ad (diff)
downloadkdepimpi-0f45c977d7530b6ca827b7a7c7da7469f01800ca.zip
kdepimpi-0f45c977d7530b6ca827b7a7c7da7469f01800ca.tar.gz
kdepimpi-0f45c977d7530b6ca827b7a7c7da7469f01800ca.tar.bz2
More config changes
Diffstat (limited to 'kmicromail/accountview.cpp') (more/less context) (show whitespace changes)
-rw-r--r--kmicromail/accountview.cpp27
1 files changed, 27 insertions, 0 deletions
diff --git a/kmicromail/accountview.cpp b/kmicromail/accountview.cpp
index 4ead545..85523b1 100644
--- a/kmicromail/accountview.cpp
+++ b/kmicromail/accountview.cpp
@@ -139,6 +139,33 @@ void AccountView::setupFolderselect(Selectstore*sels)
sels->addAccounts(imapAccounts[i]->getWrapper(),imapAccounts[i]->subFolders());
}
}
+void AccountView::downloadMailsInbox(const FolderP&fromFolder,AbstractMail*fromWrapper)
+{
+ AbstractMail*targetMail = 0;
+ QString targetFolder = "";
+ Selectstore sels;
+ setupFolderselect(&sels);
+ if (!sels.exec()) return;
+ targetMail = sels.currentMail();
+ targetFolder = sels.currentFolder();
+ if ( (fromWrapper==targetMail && fromFolder->getName()==targetFolder) ||
+ targetFolder.isEmpty())
+ {
+ return;
+ }
+ if (sels.newFolder() && !targetMail->createMbox(targetFolder))
+ {
+ QMessageBox::critical(0,tr("Error creating new Folder"),
+ tr("<center>Error while creating<br>new folder - breaking.</center>"));
+ return;
+ }
+ int maxsize = 0;
+ if ( sels.useSize->isChecked())
+ maxsize = sels.sizeSpinBox->value();
+
+ fromWrapper->mvcpAllMails(fromFolder,targetFolder,targetMail,sels.moveMails(), maxsize);
+ refreshCurrent();
+}
void AccountView::downloadMails(const FolderP&fromFolder,AbstractMail*fromWrapper)
{