summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--kmicromail/accountitem.cpp14
-rw-r--r--kmicromail/libmailwrapper/imapwrapper.cpp4
-rw-r--r--kmicromail/libmailwrapper/mhwrapper.cpp2
-rw-r--r--kmicromail/libmailwrapper/settings.cpp4
-rw-r--r--kmicromail/mainwindow.cpp7
-rw-r--r--kmicromail/mainwindow.h1
-rw-r--r--kmicromail/opiemail.cpp10
-rw-r--r--kmicromail/opiemail.h1
8 files changed, 28 insertions, 15 deletions
diff --git a/kmicromail/accountitem.cpp b/kmicromail/accountitem.cpp
index 7b9b881..59c8abb 100644
--- a/kmicromail/accountitem.cpp
+++ b/kmicromail/accountitem.cpp
@@ -18,2 +18,4 @@
+#define GET_NEW_MAILS 101
+
using namespace Opie::Core;
@@ -94,3 +96,3 @@ QPopupMenu * POP3viewItem::getContextMenu()
m->insertItem(QObject::tr("Set offline",contextName),1);
- m->insertItem(QObject::tr("Download new INBOX messages",contextName),2);
+ m->insertItem(QObject::tr("Get new messages",contextName),GET_NEW_MAILS);
}
@@ -99,3 +101,3 @@ QPopupMenu * POP3viewItem::getContextMenu()
m->insertItem(QObject::tr("Set online",contextName),1);
- m->insertItem(QObject::tr("Download new INBOX messages",contextName),2);
+ m->insertItem(QObject::tr("Get new messages",contextName),GET_NEW_MAILS);
}
@@ -139,3 +141,3 @@ void POP3viewItem::contextMenuSelected(int which)
break;
- case 2: // daunlood
+ case GET_NEW_MAILS: // daunlood
if (account->getOffline())
@@ -519,3 +521,3 @@ QPopupMenu * IMAPviewItem::getContextMenu()
m->insertSeparator();
- m->insertItem(QObject::tr("Download new INBOX messages",contextName),4);
+ m->insertItem(QObject::tr("Get new messages",contextName),GET_NEW_MAILS);
}
@@ -525,3 +527,3 @@ QPopupMenu * IMAPviewItem::getContextMenu()
m->insertSeparator();
- m->insertItem(QObject::tr("Download new INBOX messages",contextName),4);
+ m->insertItem(QObject::tr("Get new messages",contextName),GET_NEW_MAILS);
}
@@ -579,3 +581,3 @@ void IMAPviewItem::contextMenuSelected(int id)
break;
- case 4: // daunlood
+ case GET_NEW_MAILS: // daunlood
{
diff --git a/kmicromail/libmailwrapper/imapwrapper.cpp b/kmicromail/libmailwrapper/imapwrapper.cpp
index 5441a9b..91332c3 100644
--- a/kmicromail/libmailwrapper/imapwrapper.cpp
+++ b/kmicromail/libmailwrapper/imapwrapper.cpp
@@ -173,3 +173,3 @@ void IMAPwrapper::login()
if ( ssl ) {
- qDebug("using ssl ");
+ //qDebug("using ssl ");
err = mailimap_ssl_connect( m_imap, (char*)server.latin1(), port );
@@ -1249,3 +1249,3 @@ void IMAPwrapper::mvcpAllMails(const FolderP&fromFolder,
AbstractMail::mvcpAllMails(fromFolder,targetFolder,targetWrapper,moveit, maxSizeInKb);
- qDebug("IMAPwrapper::mvcpAllMails::Using generic");
+ //qDebug("IMAPwrapper::mvcpAllMails::Using generic");
// odebug << "Using generic" << oendl;
diff --git a/kmicromail/libmailwrapper/mhwrapper.cpp b/kmicromail/libmailwrapper/mhwrapper.cpp
index 962dac0..641d4d9 100644
--- a/kmicromail/libmailwrapper/mhwrapper.cpp
+++ b/kmicromail/libmailwrapper/mhwrapper.cpp
@@ -67,3 +67,2 @@ void MHwrapper::listMessages(const QString & mailbox, QValueList<Opie::Core::OSm
{
- qDebug("MHwrapper::listMessages ");
init_storage();
@@ -196,3 +195,2 @@ int MHwrapper::createMbox(const QString&folder,const FolderP&pfolder,const QStri
}
- qDebug("Folder created ");
return 1;
diff --git a/kmicromail/libmailwrapper/settings.cpp b/kmicromail/libmailwrapper/settings.cpp
index 766eba0..40b5591 100644
--- a/kmicromail/libmailwrapper/settings.cpp
+++ b/kmicromail/libmailwrapper/settings.cpp
@@ -28,3 +28,2 @@ void Settings::checkDirectory()
{
- qDebug("Settings::checkDirectory() ");
return;
@@ -212,3 +211,2 @@ void IMAPaccount::read()
leaveOnServer = conf->readBoolEntry("LeaveOnServer",false);
- qDebug("reading last fetch: %d ", lf);
if ( lf < 0 ) lf = 0;
@@ -220,3 +218,3 @@ void IMAPaccount::save()
{
- qDebug("saving %s ",getFileName().latin1() );
+
Settings::checkDirectory();
diff --git a/kmicromail/mainwindow.cpp b/kmicromail/mainwindow.cpp
index 21edfd2..5f777a3 100644
--- a/kmicromail/mainwindow.cpp
+++ b/kmicromail/mainwindow.cpp
@@ -37,3 +37,8 @@ MainWindow::MainWindow( QWidget *parent, const char *name, WFlags flags )
-
+ QAction* getMail = new QAction( tr( "Get new mail" ), SmallIcon("add"),
+ 0, 0, this );
+ getMail->addTo( toolBar );
+ getMail->addTo( mailMenu );
+ connect(getMail, SIGNAL( activated() ),
+ SLOT( slotGetMail() ) );
diff --git a/kmicromail/mainwindow.h b/kmicromail/mainwindow.h
index 680f0a9..ff0ff20 100644
--- a/kmicromail/mainwindow.h
+++ b/kmicromail/mainwindow.h
@@ -43,2 +43,3 @@ protected slots:
virtual void displayMail();
+ virtual void slotGetMail() = 0;
virtual void slotDeleteMail();
diff --git a/kmicromail/opiemail.cpp b/kmicromail/opiemail.cpp
index b2119e6..19ffdb3 100644
--- a/kmicromail/opiemail.cpp
+++ b/kmicromail/opiemail.cpp
@@ -11,2 +11,3 @@
#include "selectsmtp.h"
+#include "accountitem.h"
@@ -246,3 +247,10 @@ void OpieMail::displayMail()
}
-
+void OpieMail::slotGetMail()
+{
+ QListViewItem * item = folderView->currentItem();
+ if ( ! item ) return;
+ while ( item->parent () )
+ item = item->parent ();
+ ((AccountViewItem *)item)->contextMenuSelected( 101 );
+}
void OpieMail::slotDeleteMail()
diff --git a/kmicromail/opiemail.h b/kmicromail/opiemail.h
index 1de5f6b..e054b9e 100644
--- a/kmicromail/opiemail.h
+++ b/kmicromail/opiemail.h
@@ -32,2 +32,3 @@ protected slots:
virtual void slotDeleteMail();
+ virtual void slotGetMail();
virtual void slotDeleteAllMail();