• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • kdepim
  • Sitemap
  • Contact Us
 

kmail

kmsender.h

Go to the documentation of this file.
00001 /*
00002  * kmail: KDE mail client
00003  * Copyright (c) 1996-1998 Stefan Taferner <taferner@kde.org>
00004  *
00005  * This program is free software; you can redistribute it and/or modify
00006  * it under the terms of the GNU General Public License as published by
00007  * the Free Software Foundation; either version 2 of the License, or
00008  * (at your option) any later version.
00009  *
00010  * This program is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  *
00015  * You should have received a copy of the GNU General Public License along
00016  * with this program; if not, write to the Free Software Foundation, Inc.,
00017  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
00018  */
00019 #ifndef kmsender_h
00020 #define kmsender_h
00021 #include "messagesender.h"
00022 
00023 #ifndef KDE_USE_FINAL
00024 # ifndef REALLY_WANT_KMSENDER
00025 #  error Do not include kmsender.h, but messagesender.h.
00026 # endif
00027 #endif
00028 
00029 #include <QByteArray>
00030 #include <QString>
00031 #include <QStringList>
00032 #include <QMap>
00033 #include <QObject>
00034 #include <kdeversion.h>
00035 
00036 class KMMessage;
00037 class KMFolder;
00038 class KJob;
00039 
00040 namespace KPIM {
00041   class ProgressItem;
00042 }
00043 namespace MailTransport {
00044   class TransportJob;
00045 }
00046 
00047 class KMSender: public QObject, public KMail::MessageSender
00048 {
00049   Q_OBJECT
00050 
00051 public:
00052   KMSender();
00053   ~KMSender();
00054 
00055 protected:
00063   bool doSend(KMMessage* msg, short sendNow);
00064 
00068   bool doSendQueued( const QString& transport=QString() );
00069 
00070 private:
00072   bool sending() const { return mSendInProgress; }
00073 
00074 public:
00077   bool sendImmediate() const { return mSendImmediate; }
00078   void setSendImmediate(bool);
00079 
00082   bool sendQuotedPrintable() const { return mSendQuotedPrintable; }
00083   void setSendQuotedPrintable(bool);
00084 
00085 public:
00087   void readConfig();
00088 
00090   void writeConfig(bool withSync=true);
00091 
00092 private:
00094   void setStatusMsg(const QString&);
00095 
00097   void setStatusByLink(const KMMessage *aMsg);
00098 
00099 private slots:
00100   void slotResult( KJob* job );
00101 
00104   void slotProcessedSize( KJob *job, qulonglong size );
00105 
00107   void slotAbortSend();
00108 
00110   void outboxMsgAdded(int idx);
00111 
00112 private:
00114   void doSendMsg();
00115 
00117   void cleanup();
00118 
00122   bool settingsOk() const;
00123 
00124 private:
00125   bool mSendImmediate;
00126   bool mSendQuotedPrintable;
00127 
00128   MailTransport::TransportJob* mTransportJob;
00129 
00130   QString mCustomTransport;
00131   bool mSentOk, mSendAborted;
00132   QString mErrorMsg;
00133   QString mMethodStr;
00134   bool mSendProcStarted;
00135   bool mSendInProgress;
00136   KMFolder *mOutboxFolder;
00137   KMFolder *mSentFolder;
00138   KMMessage * mCurrentMsg;
00139   KPIM::ProgressItem* mProgressItem;
00140   int mSentMessages, mTotalMessages;
00141   int mSentBytes, mTotalBytes;
00142   int mFailedMessages;
00143 };
00144 
00145 #endif /*kmsender_h*/

kmail

Skip menu "kmail"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdepim

Skip menu "kdepim"
  • akonadi
  •   clients
  •   kabc
  •   kcal
  •   kcm
  • akregator
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt
  • kdgantt1
  • kjots
  • kleopatra
  • kmail
  • kmobiletools
  • knode
  • knotes
  • kontact
  • kontactinterfaces
  • korganizer
  •   korgac
  • kpilot
  • ktimetracker
  • libkdepim
  • libkholidays
  • libkleo
  • libkpgp
  • maildir
Generated for kdepim by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal