#include <configelem.h>
Signals | |
void | sigDeleteReady (QString account) |
void | sigShowBodiesReady (QString account) |
void | sigConfigChanged () |
void | sigMessageWindowOpened () |
void | sigMessageWindowClosed () |
void | sigRefreshReady (QString account) |
Public Member Functions | |
ConfigElem () | |
ConfigElem (ConfigList *config) | |
ConfigElem (ConfigElem *pElem) | |
ConfigElem (ConfigList *config, const QString &account) | |
~ConfigElem () | |
bool | isActive () const |
void | setActive (bool active) |
QString | getAccountName () const |
void | setAccountName (QString name) |
QString | getPassword () const |
void | setPassword (const QString &password) |
bool | hasPassword () const |
KURL | getURL () const |
void | setListViewItem (QListViewItem *item) |
QListViewItem * | getListViewItem () |
bool | isSelected () const |
void | clearMailList () |
void | setHost (const QString &host) |
QString | getHost () const |
void | setProtocol (const QString &protocol) |
QString | getProtocol (bool upperCase=false) const |
void | setTLS (bool tls) |
bool | getTLS () const |
void | setPort (unsigned short int port) |
unsigned short int | getPort () const |
void | setUser (const QString &user) |
QString | getUser () const |
void | setPasswordStorage (int storage) |
int | getPasswordStorage () const |
void | saveOptions (QDomDocument &doc, QDomElement &parent) |
void | readStoredMails (QDomElement &parent) |
int | count () |
void | deleteSelectedMails () |
void | showSelectedMails () |
bool | assertPassword (bool force=false) |
Types::AccountState_Type | getState () |
QStringList | getSelectedSubjects () const |
bool | hasSelectedMails () |
void | refreshMailList (FilterLog *log=NULL) |
int | getNumberNewMails () |
int | getNumberMails () |
long | getTotalSize () |
void | fillMailListView (KshowmailView *view) |
void | refreshAccountListItem () |
void | killPOP3Job () |
int | showSelectedHeaders () |
void | printSetup () const |
void | reloadFilterSettings () |
Static Public Attributes | |
static const int | continueShowHeaders |
static const int | cancelShowHeaders |
Protected Member Functions | |
bool | isSpam (QByteArray mail) const |
bool | isSpamAssassinRunning () const |
Private Slots | |
void | slotMailDeleted (KIO::Job *job) |
void | slotFinalizeDeletion (KIO::Job *) |
void | slotBodyDownloaded (KIO::Job *job) |
void | slotMailDownloadedForAction (KIO::Job *job) |
void | slotDataMailBody (KIO::Job *, const QByteArray &datas) |
void | slotFinalizeShowMail (KIO::Job *) |
void | slotTimeout () |
void | slotReceiveUID (KIO::Job *, const QByteArray &data) |
void | slotUIDsReceived (KIO::Job *job) |
void | slotReceiveSize (KIO::Job *, const QByteArray &data) |
void | slotSizesReceived (KIO::Job *job) |
void | slotFinalizeRefresh (KIO::Job *) |
void | slotHeaderDownloaded (KIO::Job *job) |
void | slotReceiveHeader (KIO::Job *, const QByteArray &data) |
Private Member Functions | |
void | init () |
void | deleteNextMail () |
void | commitDeletion () |
void | showNextMail () |
void | commitDownloading () |
void | startKIOJob (const QString &path) |
unsigned int | getTimeoutTime () |
void | getUIDs () |
void | getSizes () |
void | getHeaders () |
void | getNextHeader () |
void | copyHeaders () |
void | applyFilters () |
void | applyFiltersDeleted () |
void | cancelRefresh () |
void | commitRefresh () |
void | swapMailLists () |
void | doDownloadActions () |
void | getNextMailForDownloadActions () |
bool | isMailDir (const QDir &path) |
bool | writeToMailBox (const QString &mail, const QString &box) |
Private Attributes | |
ConfigList * | appConfig |
FilterLog * | FLog |
Types::AccountState_Type | state |
int | PasswordStorage |
bool | m_bActive |
QString | m_strAccount |
QListViewItem * | m_pViewItem |
ShowRecord * | m_pshowrecord |
KURL | m_url |
int | secureLoginType |
bool | useTLS |
QByteArray | mailbody |
MailNumberList_Type | MailsToDelete |
MailToDownloadMap_Type | MailsToDownload |
MailNumberList_Type | MailsToShow |
MailNumberList_Type | newMails |
KIO::TransferJob * | pop3Job |
QTimer * | pop3Timer |
ShowRecord * | tempMailList |
QStringList | receivedUIDs |
QStringList | receivedSizes |
QByteArray | receivedHeader |
HeaderFilter | headerFilter |
bool | filterApplied |
bool | deletionPerformedByFilters |
bool | refreshPerformedByFilters |
bool | downloadActionsInvoked |
int | moveCounter |
Contains all datas of the account like server, user password and so on. It also contains the mails read from the server. Used in class ConfigList and ConfigAccounts.
ConfigAccounts::Accounts
ConfigElem::ConfigElem | ( | ) |
General Constructor Warning: The pointer to the application configuration (ConfigList) will not be set.
ConfigElem::ConfigElem | ( | ConfigList * | config | ) |
Default Constructor
config | pointer to the general app configuration |
ConfigElem::ConfigElem | ( | ConfigElem * | pElem | ) |
Copy Constructor. It doesn't copy the mail list but creates a new empty one. The pointer to the appropriate account list view item is set to NULL.The new account is active by default.
pElem | the account which will be copied |
ConfigElem::ConfigElem | ( | ConfigList * | config, | |
const QString & | account | |||
) |
Constructs a account which is called like the given name. Creates a empty mail list. Sets the pointer to the appropriate account list view item to NULL. The account is deactivated by default. The url doesn't contain any server informations.
config | pointer to the general app configuration | |
account | name of the new account |
ConfigElem::~ConfigElem | ( | ) |
Destructor Does nothing.
bool ConfigElem::isActive | ( | ) | const |
Returns whether the account is active.
void ConfigElem::setActive | ( | bool | active | ) |
Sets the account active.
active | TRUE - active account; FALSE - deactivate account |
QString ConfigElem::getAccountName | ( | ) | const |
Gets the account name.
void ConfigElem::setAccountName | ( | QString | name | ) |
Sets the account name.
name | the account name |
QString ConfigElem::getPassword | ( | ) | const |
Gets the account password.
void ConfigElem::setPassword | ( | const QString & | password | ) |
Sets the account password. To save it in the configuration file call saveOptions().
password | new password |
bool ConfigElem::hasPassword | ( | ) | const |
Returns whether a password is stored.
KURL ConfigElem::getURL | ( | ) | const |
Returns the url of this account.
void ConfigElem::setListViewItem | ( | QListViewItem * | item | ) |
Sets the pointer to the item in the account list view item.
item | account list view item |
QListViewItem * ConfigElem::getListViewItem | ( | ) |
Returns the pointer to the account list view item.
bool ConfigElem::isSelected | ( | ) | const |
Returns TRUE, if the appropriate list view item is selected.
FALSE - list view item is not selected
void ConfigElem::clearMailList | ( | ) |
Clears the mail list or creates a new one.
void ConfigElem::setHost | ( | const QString & | host | ) |
Sets the host name.
host | host name |
QString ConfigElem::getHost | ( | ) | const |
Returns the hostname.
void ConfigElem::setProtocol | ( | const QString & | protocol | ) |
Sets the protocol.
protocol | the protocol |
QString ConfigElem::getProtocol | ( | bool | upperCase = false |
) | const |
Returns the protocol.
upperCase | TRUE - transforms the protocol string to upper case |
void ConfigElem::setTLS | ( | bool | tls | ) |
Enable or disable TLS.
tls | TRUE: use TLS; FALSE: don't use TLS |
bool ConfigElem::getTLS | ( | ) | const |
Returns whether TLS is enabled.
FALSE: TLS is disabled
void ConfigElem::setPort | ( | unsigned short int | port | ) |
Sets the port.
port | the port |
unsigned short int ConfigElem::getPort | ( | ) | const |
Returns the port number.
void ConfigElem::setUser | ( | const QString & | user | ) |
Sets the user.
user | username |
QString ConfigElem::getUser | ( | ) | const |
Returns the user name.
void ConfigElem::setPasswordStorage | ( | int | storage | ) |
Sets the password storage type. The Constants are defined in constants.h
storage | type of password storage; valid values are: CONFIG_VALUE_ACCOUNT_PASSWORD_DONT_SAVE, CONFIG_VALUE_ACCOUNT_PASSWORD_SAVE_FILE, CONFIG_VALUE_ACCOUNT_PASSWORD_SAVE_KWALLET |
int ConfigElem::getPasswordStorage | ( | ) | const |
Returns the password storage type. The Constants are defined in constants.h.
void ConfigElem::saveOptions | ( | QDomDocument & | doc, | |
QDomElement & | parent | |||
) |
Saves the stored mails into the given DOM document. It doesn't create a new DOM element but used the given one. Saves the setup into the application config.
doc | DOM document which contains all application settings, mails and account settings | |
parent | DOM element in which all settings and mails of this account will be saved |
void ConfigElem::readStoredMails | ( | QDomElement & | parent | ) |
Gets the stored mails.
parent | DOM element which contains the mails of this account |
int ConfigElem::count | ( | ) |
Returns the number of stored mails.
void ConfigElem::deleteSelectedMails | ( | ) |
Deletes all selected mails. This just starts the deletion and returns after then. When the deletion is ready the signal sigDeleteReady will be emitted.
void ConfigElem::showSelectedMails | ( | ) |
Downloads and shows the bodies of all selected mails. This just starts the download and returns after then. When the download is ready and the body is shown the sigShowBodiesReady will be emitted.
bool ConfigElem::assertPassword | ( | bool | force = false |
) |
Opens a dialog to ask for a password, stores it temporarily in the account settings and emits the signal sigConfigChanged. Does not open a dialog if a password is already stored in the account settings.
force | ask for a new password even if a password is stored |
FALSE - no password is available
Types::AccountState_Type ConfigElem::getState | ( | ) |
Returns the state of the account.
QStringList ConfigElem::getSelectedSubjects | ( | ) | const |
Returns the subjects of the selected mails.
bool ConfigElem::hasSelectedMails | ( | ) |
Returns whether there are mails in the list that are selected in the list view.
FALSE - there aren't selected mails
void ConfigElem::refreshMailList | ( | FilterLog * | log = NULL |
) |
Refreshes the mail list. This just starts the refresh and returns after then. When the refresh is ready, the signal sigRefreshReady will be emitted.
log | Pointer to the filter log |
int ConfigElem::getNumberNewMails | ( | ) |
Returns the number of new mails.
int ConfigElem::getNumberMails | ( | ) |
Returns the number of mails.
long ConfigElem::getTotalSize | ( | ) |
Returns the total size of all mails.
void ConfigElem::fillMailListView | ( | KshowmailView * | view | ) |
Creates for every mail a list view item and insert it into the mail list view.
view | pointer to the application view |
void ConfigElem::refreshAccountListItem | ( | ) |
Refreshes the appropriate entry of the account list (number of mails and total size) Uses the pointer to the list view item stored in m_pViewItem.
void ConfigElem::killPOP3Job | ( | ) |
Kills a running pop3 job.
int ConfigElem::showSelectedHeaders | ( | ) |
Shows the headers of all selected mails.
cancelShowHeaders - the user has clicked Cancel. The invoking function will not show the next header.
continueShowHeaders - no mails of this account are selected
void ConfigElem::printSetup | ( | ) | const |
Prints the setup to stdout.
void ConfigElem::reloadFilterSettings | ( | ) |
Reloads the settings of the filters. It just calls the load() methode of the header filter.
void ConfigElem::init | ( | ) | [private] |
Initializes the account.
void ConfigElem::deleteNextMail | ( | ) | [private] |
Deletes the first mail of MailsToDelete. After a succesful deletion this mail will be removed from the list by slotMailDeleted() and this method will be invoked again. If the list is empty, it will call commitDelete.
void ConfigElem::commitDeletion | ( | ) | [private] |
Commits the deletion. Starts a pop3 job that will do the commit. Its signal result is connected with slotFinalizeDeletion().
void ConfigElem::showNextMail | ( | ) | [private] |
Shows the body of the first mail in MailsToShow. After a succesful download and opening of the window this mail will be removed from the list by slotBodyDownloaded() and this method will be invoked again. If the list is empty, it will call commitDownloading().
void ConfigElem::commitDownloading | ( | ) | [private] |
Commits the downloading of mail bodies. Starts a pop3 job that will do the commit. Its signal result is connected with slotFinalizeShowMail().
void ConfigElem::startKIOJob | ( | const QString & | path | ) | [private] |
Creates a POP3 transfer job (KIO Job), which will be stored in pop3Job.
path | command and parameters of the job as URL path |
unsigned int ConfigElem::getTimeoutTime | ( | ) | [private] |
Returns the timeout time in seconds which is stored in the general configuration of the application. Returns POP3_DEFAULT_TIMEOUT_TIME (defined in constants.h), if no time is available. Returns POP3_MINIMUM_TIMEOUT_TIME (defined in constants.h), if the get time is less than POP3_MINIMUM_TIMEOUT_TIME.
void ConfigElem::getUIDs | ( | ) | [private] |
First step of the refresh cycle. Gets the UIDs of the available mails from the server. It starts a KIO job to get the UIDs. The UIDs will be stored in receivedUIDs by slotReceiveUID(). When the job is ready, it will invoke slotUIDsReceived().
void ConfigElem::getSizes | ( | ) | [private] |
Second step of the refresh cycle. Gets the sizes of the available mails from the server. It starts a KIO job to get these. The Sizes will be temporarily stored in receivedSizes by slotReceiveSize(). When the job is ready, it will invoke slotSizesReceived().
void ConfigElem::getHeaders | ( | ) | [private] |
Third step of the refresh cycle. Gets the header of the new mails from the server.
void ConfigElem::getNextHeader | ( | ) | [private] |
Get the header of the first mail in newMails. After a succesful download this mail will be removed from the list by slotHeaderDownloaded() and this method will be invoked again. If the list is empty, it will call copyHeaders() to get the known headers from the old mail list (m_pshowrecord).
void ConfigElem::copyHeaders | ( | ) | [private] |
Fourth step of the refresh cycle. Copies the known headers of the old mails from the old mail list to the new one. At the end it invokes swapMailLists().
void ConfigElem::applyFilters | ( | ) | [private] |
Sixth step of the refresh cycle. Applies the filters to the mails in the mail list. Invoked by swapMailLists(). This methode maybe starts a new refresh cycle because after a deletion or moving we need a actual list of mails on the server. To avoid a never-ending loop you must not call this methode during the second refresh cycle. Therefore it sets filterApplied to TRUE.
void ConfigElem::applyFiltersDeleted | ( | ) | [private] |
If there are mails to delete by filters applyFilters will call the regular deletion cycle of this class with set byFilter-flag. Therefore the deletion will not branch to commitDeletion() but to this methode. This performs a second refresh cycle to get an effective mail list from the server. This new cycle will not apply the filters again, because the flag filterApplied is set to TRUE.
void ConfigElem::cancelRefresh | ( | ) | [private] |
Cancels the refresh. Will be invoked, when a pop3 job has reported an error.
void ConfigElem::commitRefresh | ( | ) | [private] |
Commits the refresh. Starts a pop3 job that will do the commit. Its signal result is connected with slotFinalizeRefresh(). Invoked by copyHeaders() if the filters was applied or applyFilters() if not second refresh was necessary.
void ConfigElem::swapMailLists | ( | ) | [private] |
Fifth step of the refresh cycle. Copies the pointer to the temporary list to m_pshowrecord. Invoked by copyHeaders() and slotUIDsReceived(). The temporary list will be the current mail list. At the end it invokes commitRefresh() if the filters were applied (filterApplied == TRUE) or deactive or it invokes applyFilters() if the filters were not applied (filterApplied == FALSE).
void ConfigElem::doDownloadActions | ( | ) | [private] |
Does all filter actions for which we have to download the mails These are: Moving, spam check It doesn't removes they from the server.
void ConfigElem::getNextMailForDownloadActions | ( | ) | [private] |
Gets the body of the first mail in MailsToDownload. After a succesful download and writing into the mailbox this mail will be removed from the list by slotMailDownloadedforDownloadActions() and this method will be invoked again. If the list is empty, it will call applyFilters() to continue the filtering.
slotMailDownloadedforDownloadActions()
bool ConfigElem::isMailDir | ( | const QDir & | path | ) | [private] |
Returns whether the given directory is a maildir directory
path | the directory for test |
bool ConfigElem::writeToMailBox | ( | const QString & | mail, | |
const QString & | box | |||
) | [private] |
Writes the given mail into the mailbox.
the Mail | ||
box | path to the mailbox |
void ConfigElem::slotMailDeleted | ( | KIO::Job * | job | ) | [private, slot] |
Connected with signal result of the launched pop3 job. Removes the deleted mail from the internal mail list (m_pshowrecord). Removes the first mail from MailsToDelete and invokes deleteNextMail() again to delete the next mail. If the list is empty after it has removed the first item, it will call commitDelete(). If an error is occured, it will call slotFinalizeDeletion().
job | job which has emit the result signal |
void ConfigElem::slotFinalizeDeletion | ( | KIO::Job * | ) | [private, slot] |
Connected with the signal result of the job which commits the deletion. Finalizes the deletion of mails. Emits signal sigDeleteReady.
void ConfigElem::slotBodyDownloaded | ( | KIO::Job * | job | ) | [private, slot] |
Connected with signal result of the launched pop3 job to download a mail body. Opens a window (class ShowMailDialog) with the downloaded mail body. Removes the first mail from MailsToShow and invokes showNextMail() again to show the next mail. If the list is empty after it has removed the first item, it will call commitDownloading(). If an error is occured, it will call slotFinalizeShowMail().
job | job which has emit the result signal |
void ConfigElem::slotMailDownloadedForAction | ( | KIO::Job * | job | ) | [private, slot] |
Connected with signal result of the launched pop3 job to download a mail to write it into a mailbox or do a spam check. Maybe it puts the number of the downloaded mail into the list of mails to delete (MailsToDelete). Removes the first mail from MailsToMove and invokes getNextMailForMove() again to get and write the next mail. If the list is empty after it has removed the first item, it will call applyFilters() to continue the filtering. If an error is occured the current mail will not put into MailsToDelete. And it returns to applyFilters() immediately.
job | job which has emit the result signal |
void ConfigElem::slotDataMailBody | ( | KIO::Job * | , | |
const QByteArray & | datas | |||
) | [private, slot] |
Connected with signal data of the launched pop3 job to download a mail body. Receives the downloaded data from the job. This lot will be called several times during the donwload. At the last one the array is empty. It extracts the body from the downloaded data and stores it in DownloadedMailBody.
datas | the downloaded mail |
void ConfigElem::slotFinalizeShowMail | ( | KIO::Job * | ) | [private, slot] |
Connected with the signal result of the job which commits the download of the mail bodies. Finalizes the downloading and showing of the selected mails. Emits signal sigShowBodiesReady and sets account state to idle.
void ConfigElem::slotTimeout | ( | ) | [private, slot] |
Connected with signal timeout() of the timeout timer pop3Timer. Will be called when the timer is run down, if the pop3 job has not ended on time. It kills a running pop3 job and invokes the appropriate finalize slot of the running operation.
void ConfigElem::slotReceiveUID | ( | KIO::Job * | , | |
const QByteArray & | data | |||
) | [private, slot] |
Connected with the signal "data" of the pop3 transfer job which gets mail UIDs (Unique ID). Therefore it will be called when the job has received an UIDL from the server. Every received UID causes a call of this slot. When the job ends, it causes a last call but with an empty data array. The UIDs will be stored in receivedUIDs.
data | received data, which contain an uid |
void ConfigElem::slotUIDsReceived | ( | KIO::Job * | job | ) | [private, slot] |
Connected with signal result of the launched pop3 job to get the UIDs. Will be invoked, when all UIDs are received and stored in receivedUIDs. Analyzes the received UID datas and creates new ShowRecordElem instances in the new mail list accordingly.
job | job which has emitted the result signal |
void ConfigElem::slotReceiveSize | ( | KIO::Job * | , | |
const QByteArray & | data | |||
) | [private, slot] |
Connected with the signal "data" of the pop3 transfer job which gets mail Sizes. Therefore it will be called when the job has received a size from the server. Every received size causes a call of this slot. When the job ends, it causes a last call but with an empty data array. The UIDs will be stored in receivedSizes.
data | received data, which contain a size |
void ConfigElem::slotSizesReceived | ( | KIO::Job * | job | ) | [private, slot] |
Connected with signal result of the launched pop3 job to get the Sizes. Will be invoked, when all Sizes are received and stored in receivedSizes. Analyzes the received datas and writes these in the appropriate mail instances.
job | job which has emitted the result signal |
void ConfigElem::slotFinalizeRefresh | ( | KIO::Job * | ) | [private, slot] |
Connected with signal result of the job which commits the refresh. Finalizes a succesful refresh. Emits sigRefreshReady and sets account state to idle
void ConfigElem::slotHeaderDownloaded | ( | KIO::Job * | job | ) | [private, slot] |
Connected with signal result of the launched pop3 job. Stores the received headers into the appropriate instance of the mail list. Removes the first mail from newMails and invokes getNextHeader() again to get the next header. If the list is empty after it has removed the first item, it will call copyHeaders(). If an error has occured, it will call cancelRefresh().
job | job which has emit the result signal |
void ConfigElem::slotReceiveHeader | ( | KIO::Job * | , | |
const QByteArray & | data | |||
) | [private, slot] |
Connected with the signal "data" of the pop3 transfer job which gets a mail header. Therefore it will be called when the job has received a part of the header from the server. When the job ends, it causes a last call but with an empty data array. The complete header will be stored in receivedHeader.
data | received data, which contains a header part |
void ConfigElem::sigDeleteReady | ( | QString | account | ) | [signal] |
Will be emitted when all selected mails are deleted.
account | name of the account, which has emitted this signal |
void ConfigElem::sigShowBodiesReady | ( | QString | account | ) | [signal] |
Will be emitted when the bodies of all selected mails are downloaded and shown.
account | name of the account, which has emitted this signal |
void ConfigElem::sigConfigChanged | ( | ) | [signal] |
Will be emitted when the settings have been changed.
void ConfigElem::sigMessageWindowOpened | ( | ) | [signal] |
Will be emitted, when a window to show a message was opened.
void ConfigElem::sigMessageWindowClosed | ( | ) | [signal] |
Will be emitted, when a window to show a message was closed.
void ConfigElem::sigRefreshReady | ( | QString | account | ) | [signal] |
Will be emitted, when the mail list was refreshed.
account | name of the account, which has emitted this signal |
bool ConfigElem::isSpam | ( | QByteArray | ) | const [protected] |
Forwards the given mail to SpamAssassin and returns the test result
the mail to test |
bool ConfigElem::isSpamAssassinRunning | ( | ) | const [protected] |
Looks for a running spamd daemon of SpamAssassin.
int const ConfigElem::continueShowHeaders [static] |
Returned by showSelectedHeaders(), if the user has clicked OK.
int const ConfigElem::cancelShowHeaders [static] |
Returned by showSelectedHeaders(), if the user has clicked Cancel.
ConfigList* ConfigElem::appConfig [private] |
Pointer to the configuration of the application. Set by the constructors.
FilterLog* ConfigElem::FLog [private] |
Pointer to the filter log. Will be set by refreshMailList() at every refresh.
Types::AccountState_Type ConfigElem::state [private] |
State of the account.
int ConfigElem::PasswordStorage [private] |
Type of password storage. valid values are: CONFIG_VALUE_ACCOUNT_PASSWORD_DONT_SAVE, CONFIG_VALUE_ACCOUNT_PASSWORD_SAVE_FILE, CONFIG_VALUE_ACCOUNT_PASSWORD_SAVE_KWALLET The Constants are defined in constants.h
bool ConfigElem::m_bActive [private] |
TRUE - account is active; FALSE - account is not active
QString ConfigElem::m_strAccount [private] |
Account Name
QListViewItem* ConfigElem::m_pViewItem [private] |
Pointer to the appropriate item in the account list view.
ShowRecord* ConfigElem::m_pshowrecord [private] |
List which contains all read mails from the server.
KURL ConfigElem::m_url [private] |
Uniform Resource Locator of the account on the pop3 server.
int ConfigElem::secureLoginType [private] |
Type of secure login. See constants.h for valid values (CONFIG_VALUE_ACCOUNT_SECLOGIN_...)
bool ConfigElem::useTLS [private] |
False: TLS is enabled
QByteArray ConfigElem::mailbody [private] |
Contains a downloaded mail body. Will be set by slotDataMailBody() and read by slotBodyDownloaded().
MailNumberList_Type ConfigElem::MailsToDelete [private] |
Contains the numbers of mails which will be deleted. Set by deleteSelectedMails() and applyFilters() and used by deleteNextMail() to get the number of the next mail to delete.
MailToDownloadMap_Type ConfigElem::MailsToDownload [private] |
Contains the numbers of the mails shall be moved for actions like moving to mailbox or spam check. Contains also some parameters (like mailbox) about the action which have to be performed. Set and used by applyFilters().
MailNumberList_Type ConfigElem::MailsToShow [private] |
Contains the numbers of mails for which the bodies will be shown. Set by showSelectedMails() and used by showNextMail() to get the number of the next mail to show.
MailNumberList_Type ConfigElem::newMails [private] |
Contains the numbers of new mails. Set by getHeaders() and used by getNextHeader() to download the headers of the new mails.
KIO::TransferJob* ConfigElem::pop3Job [private] |
Pointer to a launched pop3 job.
QTimer* ConfigElem::pop3Timer [private] |
timeout timer. Will be started together with every pop3 job. If it runs down, slotTimeout() will be invoked.
ShowRecord* ConfigElem::tempMailList [private] |
While refreshing, this ShowRecord instance will be used to build a new mail list. After that this pointer will be assigned to m_pshowrecord.
QStringList ConfigElem::receivedUIDs [private] |
List of received mail UIDs (unique ID). Used by slotReceiveUID() and slotUIDsReceived().
QStringList ConfigElem::receivedSizes [private] |
List of received mail sizes. Used by slotReceiveSize() and slotSizesReceived().
QByteArray ConfigElem::receivedHeader [private] |
A received mail header. Set by slotReceiveHeader() and used by slotHeaderDownloaded().
HeaderFilter ConfigElem::headerFilter [private] |
Every account has is own header filter instance.
bool ConfigElem::filterApplied [private] |
This is a flag whether the filters was applied during a refresh cycle. If the some mails was deleted (recommend by the filter), we need a actual list of mails from the server. Therefore a second refresh cycle will be started. To avoid a never-ending loop this flag will be set to TRUE by applyFilters(). If the second refresh is running this one will not invoke the filters.
bool ConfigElem::deletionPerformedByFilters [private] |
This flag is set by applyFilters() to indicate the deletion cycle is performed by filters and not by user. The deletion methodes need it to decide on branch targets
bool ConfigElem::refreshPerformedByFilters [private] |
This flag is set by applyFiltersDeleted() to indicate the refresh cycle is the second one after a deletion which was performed by filters. The refresh cycle need it to hold the remaining mails as new.
bool ConfigElem::downloadActionsInvoked [private] |
This flag is set to TRUE by applyFilters() to indicate the mailbodies are downloading and writing to the mailboxes or spam checking. When this is ended, applyFilters() will be called again and it reset this flag
int ConfigElem::moveCounter [private] |
Counter for moving to create an unique file name