From 7be55ffa061c026e35e2d6a0effe1161ddb0d41f Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:53:50 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kmail/kmfolderimap.h | 106 +++++++++++++++++++++++++-------------------------- 1 file changed, 53 insertions(+), 53 deletions(-) (limited to 'kmail/kmfolderimap.h') diff --git a/kmail/kmfolderimap.h b/kmail/kmfolderimap.h index f7c027e0e..da026728c 100644 --- a/kmail/kmfolderimap.h +++ b/kmail/kmfolderimap.h @@ -33,8 +33,8 @@ #include -#include -#include +#include +#include template< typename T> class QPtrList; template< typename T> class QValueList; @@ -80,7 +80,7 @@ class KMFolderImap : public KMFolderMbox friend class ::KMail::ImapJob; public: - static QString cacheLocation() { + static TQString cacheLocation() { return locateLocal("data", "kmail/imap" ); } @@ -108,15 +108,15 @@ public: virtual KMMessage* getMsg(int idx); /** The path to the imap folder on the server */ - void setImapPath( const QString &path ); - QString imapPath() const { return mImapPath; } + void setImapPath( const TQString &path ); + TQString imapPath() const { return mImapPath; } /** The highest UID in the folder */ ulong lastUid(); /** The uidvalidity of the last update */ - void setUidValidity(const QString &validity) { mUidValidity = validity; } - QString uidValidity() { return mUidValidity; } + void setUidValidity(const TQString &validity) { mUidValidity = validity; } + TQString uidValidity() { return mUidValidity; } /** The imap account associated with this folder */ void setAccount(KMAcctImap *acct); @@ -124,9 +124,9 @@ public: /** Remove (first occurrence of) given message from the folder. */ virtual void removeMsg(int i, bool quiet = FALSE); - virtual void removeMsg(const QPtrList& msgList, bool quiet = FALSE); + virtual void removeMsg(const TQPtrList& msgList, bool quiet = FALSE); - virtual int rename( const QString& newName, KMFolderDir *aParent = 0 ); + virtual int rename( const TQString& newName, KMFolderDir *aParent = 0 ); /** Remove the IMAP folder on the server and if successful also locally */ virtual void remove(); @@ -169,14 +169,14 @@ public: * that contain messages _or_ folders the new folder is set to "contains messages" * by default */ - void createFolder(const QString &name, - const QString& imapPath = QString::null, bool askUser = true); + void createFolder(const TQString &name, + const TQString& imapPath = TQString::null, bool askUser = true); /** * Delete a message */ void deleteMessage(KMMessage * msg); - void deleteMessage(const QPtrList& msgList); + void deleteMessage(const TQPtrList& msgList); /** * Change the status of the message indicated by @p index @@ -187,21 +187,21 @@ public: /** * Change the status of several messages indicated by @p ids */ - virtual void setStatus(QValueList& _ids, KMMsgStatus status, bool toggle); + virtual void setStatus(TQValueList& _ids, KMMsgStatus status, bool toggle); /** generates sets of uids */ - static QStringList makeSets( QValueList&, bool sort = true); - static QStringList makeSets(const QStringList&, bool sort = true); + static TQStringList makeSets( TQValueList&, bool sort = true); + static TQStringList makeSets(const TQStringList&, bool sort = true); /** splits the message list according to sets. Modifies the @msgList. */ - static QPtrList splitMessageList(const QString& set, - QPtrList& msgList); + static TQPtrList splitMessageList(const TQString& set, + TQPtrList& msgList); /** gets the uids of the given ids */ - void getUids(QValueList& ids, QValueList& uids); + void getUids(TQValueList& ids, TQValueList& uids); /** same as above but accepts a Message-List */ - void getUids(const QPtrList& msgList, QValueList& uids); + void getUids(const TQPtrList& msgList, TQValueList& uids); /** * Expunge deleted messages from the folder @@ -232,19 +232,19 @@ public: /** * Encode the given string in a filename save 7 bit string */ - static QString encodeFileName(const QString &); - static QString decodeFileName(const QString &); - static QTextCodec * utf7Codec(); + static TQString encodeFileName(const TQString &); + static TQString decodeFileName(const TQString &); + static TQTextCodec * utf7Codec(); /** * Convert message status to a list of IMAP flags */ - static QString statusToFlags(KMMsgStatus status, int supportedFalgs); + static TQString statusToFlags(KMMsgStatus status, int supportedFalgs); /** * Return the filename of the folder (reimplemented from KFolder) */ - virtual QString fileName() const { + virtual TQString fileName() const { return encodeFileName( KMFolderMbox::fileName() ); } /** @@ -261,7 +261,7 @@ public: /** * Splits a uid-set into single uids */ - static QValueList splitSets(const QString); + static TQValueList splitSets(const TQString); virtual void ignoreJobsForMessage( KMMessage* ); @@ -316,7 +316,7 @@ public: virtual bool isMoveable() const; /** Initialize this storage from another one. Used when creating a child folder */ - void initializeFrom( KMFolderImap* parent, QString path, QString mimeType ); + void initializeFrom( KMFolderImap* parent, TQString path, TQString mimeType ); /** Returns the IMAP flags that can be stored on the server. */ int permanentFlags() const { return mPermanentFlags; } @@ -339,12 +339,12 @@ signals: * @param name The name of the folder that should have been created. * @param success True if the folder was created, false otherwise. */ - void folderCreationResult( const QString &name, bool success ); + void folderCreationResult( const TQString &name, bool success ); public slots: /** Add a message to a folder after is has been added on an IMAP server */ virtual void addMsgQuiet(KMMessage *); - virtual void addMsgQuiet(QPtrList); + virtual void addMsgQuiet(TQPtrList); /** Add the given message to the folder. Usually the message is added at the end of the folder. Returns zero on success and @@ -353,21 +353,21 @@ public slots: Please note that the message is added as is to the folder and the folder takes ownership of the message (deleting it in the destructor).*/ virtual int addMsg(KMMessage* msg, int* index_return = 0); - virtual int addMsg(QPtrList&, QValueList& index_return); + virtual int addMsg(TQPtrList&, TQValueList& index_return); /** Copy the messages to this folder */ - void copyMsg(QPtrList& msgList/*, KMFolder* parent*/); + void copyMsg(TQPtrList& msgList/*, KMFolder* parent*/); /** Detach message from this folder. Usable to call addMsg() afterwards. Loads the message if it is not loaded up to now. */ virtual KMMessage* take(int idx); - virtual void take(QPtrList); + virtual void take(TQPtrList); /** * Add the data a KIO::Job retrieves to the buffer */ - void slotSimpleData(KIO::Job * job, const QByteArray & data); + void slotSimpleData(KIO::Job * job, const TQByteArray & data); /** * Convert IMAP flags to a message status @@ -389,7 +389,7 @@ public slots: /** * Called from the SearchJob when the folder is done or messages where found */ - void slotSearchDone( QValueList serNums, + void slotSearchDone( TQValueList serNums, const KMSearchPattern* pattern, bool complete ); @@ -402,21 +402,21 @@ public slots: * Connected to ListJob::receivedFolders * creates/removes folders */ - void slotListResult( const QStringList&, const QStringList&, - const QStringList&, const QStringList&, const ImapAccountBase::jobData& ); + void slotListResult( const TQStringList&, const TQStringList&, + const TQStringList&, const TQStringList&, const ImapAccountBase::jobData& ); /** * Connected to slotListNamespaces * creates/removes namespace folders */ - void slotCheckNamespace( const QStringList&, const QStringList&, - const QStringList&, const QStringList&, const ImapAccountBase::jobData& ); + void slotCheckNamespace( const TQStringList&, const TQStringList&, + const TQStringList&, const TQStringList&, const ImapAccountBase::jobData& ); protected: virtual FolderJob* doCreateJob( KMMessage *msg, FolderJob::JobType jt, - KMFolder *folder, QString partSpecifier, + KMFolder *folder, TQString partSpecifier, const AttachmentStrategy *as ) const; - virtual FolderJob* doCreateJob( QPtrList& msgList, const QString& sets, + virtual FolderJob* doCreateJob( TQPtrList& msgList, const TQString& sets, FolderJob::JobType jt, KMFolder *folder ) const; void getMessagesResult(KIO::Job * job, bool lastSet); @@ -426,16 +426,16 @@ protected: the various index files deleted. Returns 0 on success. */ virtual int expungeContents(); - void setChildrenState( QString attributes ); + void setChildrenState( TQString attributes ); /** Create or find the INBOX and initialize it */ void initInbox(); /** See if there is a better parent then this folder */ - KMFolderImap* findParent( const QString& path, const QString& name ); + KMFolderImap* findParent( const TQString& path, const TQString& name ); /** See if all folders are still present on server, otherwise delete them */ - void checkFolders( const QStringList& folderNames, const QString& ns ); + void checkFolders( const TQStringList& folderNames, const TQString& ns ); void finishMailCheck( const char *func, imapState state ); @@ -450,7 +450,7 @@ protected slots: /** * Get the folder now (internal) */ - void reallyGetFolder(const QString &startUid = QString::null); + void reallyGetFolder(const TQString &startUid = TQString::null); /** * For listing the contents of a folder @@ -463,7 +463,7 @@ protected slots: */ void slotGetMessagesResult(KIO::Job * job); void slotGetLastMessagesResult(KIO::Job * job); - void slotGetMessagesData(KIO::Job * job, const QByteArray & data); + void slotGetMessagesData(KIO::Job * job, const TQByteArray & data); /** * For creating a new subfolder @@ -489,14 +489,14 @@ protected slots: /** * Is called when the slave is connected and triggers a newmail check */ - void slotProcessNewMail( int errorCode, const QString& errorMsg ); + void slotProcessNewMail( int errorCode, const TQString& errorMsg ); /** * Is connected when there are folders to be created on startup and the * account is still connecting. Once the account emits the connected * signal this slot is called and the folders created. */ - void slotCreatePendingFolders( int errorCode, const QString& errorMsg ); + void slotCreatePendingFolders( int errorCode, const TQString& errorMsg ); /** * Starts a namespace listing @@ -504,35 +504,35 @@ protected slots: void slotListNamespaces(); protected: - QString mImapPath; + TQString mImapPath; ulong mLastUid; imapState mContentState, mSubfolderState; bool mIsSelected; bool mCheckFlags; bool mReadOnly; bool mCheckMail; - mutable QGuardedPtr mAccount; + mutable TQGuardedPtr mAccount; // the current uidvalidity - QString mUidValidity; + TQString mUidValidity; unsigned int mUserRights; private: // if we're checking validity currently bool mCheckingValidity; // uid - metadata cache - QIntDict mUidMetaDataMap; + TQIntDict mUidMetaDataMap; // msgidMD5 - status map - QDict mMetaDataMap; + TQDict mMetaDataMap; // if the folder should be deleted without server roundtrip bool mAlreadyRemoved; // the progress for mailchecks - QGuardedPtr mMailCheckProgressItem; + TQGuardedPtr mMailCheckProgressItem; // the progress for listings ProgressItem *mListDirProgressItem; // the progress for addMsg ProgressItem *mAddMessageProgressItem; // to-be-added folders - QStringList mFoldersPendingCreation; + TQStringList mFoldersPendingCreation; // push all flags to the server instead of just the changed once // when doing a flag change the next time -- cgit v1.2.1