diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:53:50 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:53:50 +0000 |
commit | 7be55ffa061c026e35e2d6a0effe1161ddb0d41f (patch) | |
tree | 8474f9b444b2756228600050f07a7ff25de532b2 /kmail/kmailicalifaceimpl.h | |
parent | f587f20a6d09f1729dd0a8c1cd8ee0110aec7451 (diff) | |
download | tdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.tar.gz tdepim-7be55ffa061c026e35e2d6a0effe1161ddb0d41f.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1157655 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kmail/kmailicalifaceimpl.h')
-rw-r--r-- | kmail/kmailicalifaceimpl.h | 140 |
1 files changed, 70 insertions, 70 deletions
diff --git a/kmail/kmailicalifaceimpl.h b/kmail/kmailicalifaceimpl.h index 261774860..5a92ffe92 100644 --- a/kmail/kmailicalifaceimpl.h +++ b/kmail/kmailicalifaceimpl.h @@ -42,9 +42,9 @@ #include "kmfoldertype.h" #include <kfoldertree.h> -#include <qdict.h> -#include <qguardedptr.h> -#include <qmap.h> +#include <tqdict.h> +#include <tqguardedptr.h> +#include <tqmap.h> class KMFolder; class KMMessage; @@ -58,84 +58,84 @@ class ExtraFolder { public: ExtraFolder( KMFolder* f ); ~ExtraFolder(); - QGuardedPtr<KMFolder> folder; + TQGuardedPtr<KMFolder> folder; }; class Accumulator { public: - Accumulator( const QString& t, const QString& f, int c ) + Accumulator( const TQString& t, const TQString& f, int c ) :type( t ), folder( f ), count( c ) {} - void add( const QString& incidence ) { + void add( const TQString& incidence ) { incidences << incidence; count--; } bool isFull() { return count == 0; } - const QString type; - const QString folder; - QStringList incidences; + const TQString type; + const TQString folder; + TQStringList incidences; int count; }; } /** The implementation of the interface. */ -class KMailICalIfaceImpl : public QObject, virtual public KMailICalIface { +class KMailICalIfaceImpl : public TQObject, virtual public KMailICalIface { Q_OBJECT public: KMailICalIfaceImpl(); - bool isWritableFolder( const QString& type, const QString& resource ); + bool isWritableFolder( const TQString& type, const TQString& resource ); - StorageFormat storageFormat( const QString &resource ); + StorageFormat storageFormat( const TQString &resource ); /// Update a kolab storage entry. /// If message is not there, it is added and /// given the subject as Subject: header. /// Returns the new mail serial number, /// or 0 if something went wrong, - Q_UINT32 update( const QString& resource, + Q_UINT32 update( const TQString& resource, Q_UINT32 sernum, - const QString& subject, - const QString& plainTextBody, - const QMap<QCString, QString>& customHeaders, - const QStringList& attachmentURLs, - const QStringList& attachmentMimetypes, - const QStringList& attachmentNames, - const QStringList& deletedAttachments ); - - bool deleteIncidenceKolab( const QString& resource, + const TQString& subject, + const TQString& plainTextBody, + const TQMap<TQCString, TQString>& customHeaders, + const TQStringList& attachmentURLs, + const TQStringList& attachmentMimetypes, + const TQStringList& attachmentNames, + const TQStringList& deletedAttachments ); + + bool deleteIncidenceKolab( const TQString& resource, Q_UINT32 sernum ); - int incidencesKolabCount( const QString& mimetype, - const QString& resource ); - QMap<Q_UINT32, QString> incidencesKolab( const QString& mimetype, - const QString& resource, + int incidencesKolabCount( const TQString& mimetype, + const TQString& resource ); + TQMap<Q_UINT32, TQString> incidencesKolab( const TQString& mimetype, + const TQString& resource, int startIndex, int nbMessages ); - QValueList<SubResource> subresourcesKolab( const QString& contentsType ); + TQValueList<SubResource> subresourcesKolab( const TQString& contentsType ); - bool triggerSync( const QString& contentsType ); + bool triggerSync( const TQString& contentsType ); // "Get" an attachment. This actually saves the attachment in a file // and returns a URL to it - KURL getAttachment( const QString& resource, + KURL getAttachment( const TQString& resource, Q_UINT32 sernum, - const QString& filename ); + const TQString& filename ); - QString attachmentMimetype( const QString &resource, + TQString attachmentMimetype( const TQString &resource, Q_UINT32 sernum, - const QString &filename ); + const TQString &filename ); - QStringList listAttachments( const QString &resource, Q_UINT32 sernum ); + TQStringList listAttachments( const TQString &resource, Q_UINT32 sernum ); - bool removeSubresource( const QString& ); + bool removeSubresource( const TQString& ); - bool addSubresource( const QString& resource, - const QString& parent, - const QString& contentsType ); + bool addSubresource( const TQString& resource, + const TQString& parent, + const TQString& contentsType ); // tell KOrganizer about messages to be deleted void msgRemoved( KMFolder*, KMMessage* ); @@ -177,22 +177,22 @@ public: /** * Returns the name of the standard icon for a folder of given type or - * QString::null if the type is no groupware type. + * TQString::null if the type is no groupware type. */ - QString folderPixmap( KFolderTreeItem::Type type ) const; + TQString folderPixmap( KFolderTreeItem::Type type ) const; /** Returns the localized name of a folder of given type. */ - QString folderName( KFolderTreeItem::Type type, int language = -1 ) const; + TQString folderName( KFolderTreeItem::Type type, int language = -1 ) const; /** Get the folder that holds *type* entries */ - KMFolder* folderFromType( const QString& type, const QString& folder ); + KMFolder* folderFromType( const TQString& type, const TQString& folder ); /** Return the ical type of a folder */ - QString icalFolderType( KMFolder* folder ) const; + TQString icalFolderType( KMFolder* folder ) const; /** Find message matching a given UID. */ - KMMessage* findMessageByUID( const QString& uid, KMFolder* folder ); + KMMessage* findMessageByUID( const TQString& uid, KMFolder* folder ); /** Find message matching a given serial number. */ static KMMessage* findMessageBySerNum( Q_UINT32 serNum, KMFolder* folder ); @@ -230,7 +230,7 @@ public slots: void slotIncidenceAdded( KMFolder* folder, Q_UINT32 sernum ); void slotIncidenceDeleted( KMFolder* folder, Q_UINT32 sernum ); - void slotRefresh( const QString& type); + void slotRefresh( const TQString& type); // Called when a folder is made readonly or readwrite, or renamed, // or any other similar change that affects the resources @@ -239,7 +239,7 @@ public slots: private slots: void slotRefreshFolder( KMFolder* ); void slotCheckDone(); - void slotFolderLocationChanged( const QString&, const QString& ); + void slotFolderLocationChanged( const TQString&, const TQString& ); void slotFolderRenamed(); void slotMessageRetrieved( KMMessage* ); @@ -250,7 +250,7 @@ private: void connectFolder( KMFolder* folder ); - KMFolder* extraFolder( const QString& type, const QString& folder ); + KMFolder* extraFolder( const TQString& type, const TQString& folder ); void syncFolder( KMFolder* folder ) const; @@ -264,24 +264,24 @@ private: }; StandardFolderSearchResult findStandardResourceFolder( KMFolderDir* folderParentDir, KMail::FolderContentsType contentsType ); - KMFolder* findResourceFolder( const QString& resource ); + KMFolder* findResourceFolder( const TQString& resource ); bool updateAttachment( KMMessage& msg, - const QString& attachmentURL, - const QString& attachmentName, - const QString& attachmentMimetype, + const TQString& attachmentURL, + const TQString& attachmentName, + const TQString& attachmentMimetype, bool lookupByName ); bool deleteAttachment( KMMessage& msg, - const QString& attachmentURL ); + const TQString& attachmentURL ); Q_UINT32 addIncidenceKolab( KMFolder& folder, - const QString& subject, - const QString& plainTextBody, - const QMap<QCString, QString>& customHeaders, - const QStringList& attachmentURLs, - const QStringList& attachmentNames, - const QStringList& attachmentMimetypes ); - static bool kolabXMLFoundAndDecoded( const KMMessage& msg, const QString& mimetype, QString& s ); + const TQString& subject, + const TQString& plainTextBody, + const TQMap<TQCString, TQString>& customHeaders, + const TQStringList& attachmentURLs, + const TQStringList& attachmentNames, + const TQStringList& attachmentMimetypes ); + static bool kolabXMLFoundAndDecoded( const KMMessage& msg, const TQString& mimetype, TQString& s ); void handleFolderSynced( KMFolder* folder, const KURL& folderURL, @@ -293,17 +293,17 @@ private: static bool folderIsAlarmRelevant( const KMFolder * ); private: - QGuardedPtr<KMFolder> mContacts; - QGuardedPtr<KMFolder> mCalendar; - QGuardedPtr<KMFolder> mNotes; - QGuardedPtr<KMFolder> mTasks; - QGuardedPtr<KMFolder> mJournals; + TQGuardedPtr<KMFolder> mContacts; + TQGuardedPtr<KMFolder> mCalendar; + TQGuardedPtr<KMFolder> mNotes; + TQGuardedPtr<KMFolder> mTasks; + TQGuardedPtr<KMFolder> mJournals; // The extra IMAP resource folders // Key: folder location. Data: folder. - QDict<KMail::ExtraFolder> mExtraFolders; + TQDict<KMail::ExtraFolder> mExtraFolders; // used for collecting incidences during async loading - QDict<KMail::Accumulator> mAccumulators; + TQDict<KMail::Accumulator> mAccumulators; // More info for each folder we care about (mContacts etc. as well as the extra folders) // The reason for storing it here is that it can be shared between // kmfoldercachedimap and kmfolderimap, and that it's groupware data anyway. @@ -315,7 +315,7 @@ private: FolderChanges mChanges; }; // The storage format used for each folder that we care about - typedef QMap<KMFolder*, FolderInfo> FolderInfoMap; + typedef TQMap<KMFolder*, FolderInfo> FolderInfoMap; // helper for reading the FolderInfo from the config file FolderInfo readFolderInfo( const KMFolder * const folder ) const; @@ -337,10 +337,10 @@ private: * Since these are transient attributes of only a small but changing number * of incidences they are not encapsulated in a struct or somesuch. */ - QMap<QString, Q_UINT32> mUIDToSerNum; - QMap<Q_UINT32, bool> mTheUnGetMes; - QMap<QString, QString> mPendingUpdates; - QMap<QString, bool> mInTransit; + TQMap<TQString, Q_UINT32> mUIDToSerNum; + TQMap<Q_UINT32, bool> mTheUnGetMes; + TQMap<TQString, TQString> mPendingUpdates; + TQMap<TQString, bool> mInTransit; }; |