Diffstat (limited to 'libkdepim/externalapphandler.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libkdepim/externalapphandler.h | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/libkdepim/externalapphandler.h b/libkdepim/externalapphandler.h index b899ad7..3247fe4 100644 --- a/libkdepim/externalapphandler.h +++ b/libkdepim/externalapphandler.h | |||
@@ -25,41 +25,44 @@ | |||
25 | Enhanced Version of the file for platform independent KDE tools. | 25 | Enhanced Version of the file for platform independent KDE tools. |
26 | Copyright (c) 2004 Ulf Schenk | 26 | Copyright (c) 2004 Ulf Schenk |
27 | 27 | ||
28 | $Id$ | 28 | $Id$ |
29 | */ | 29 | */ |
30 | 30 | ||
31 | #ifndef EXTERNALAPPHANDLER_H | 31 | #ifndef EXTERNALAPPHANDLER_H |
32 | #define EXTERNALAPPHANDLER_H | 32 | #define EXTERNALAPPHANDLER_H |
33 | 33 | ||
34 | #include <qobject.h> | 34 | #include <qobject.h> |
35 | #include <qlist.h> | 35 | #include <qlist.h> |
36 | #include <qmap.h> | 36 | #include <qmap.h> |
37 | #include <Q3PtrList> | ||
38 | //Added by qt3to4: | ||
39 | #include <Q3CString> | ||
37 | 40 | ||
38 | class QCopEnvelope; | 41 | class QCopEnvelope; |
39 | 42 | ||
40 | 43 | ||
41 | class ExternalAppHandler; | 44 | class ExternalAppHandler; |
42 | class QCopTransferItem : public QObject | 45 | class QCopTransferItem : public QObject |
43 | { | 46 | { |
44 | Q_OBJECT | 47 | Q_OBJECT |
45 | public: | 48 | public: |
46 | QCopTransferItem(int usedSourceParameters, const QString& sourceMessage, const QString& targetChannel, const QString& targetMessage); | 49 | QCopTransferItem(int usedSourceParameters, const QString& sourceMessage, const QString& targetChannel, const QString& targetMessage); |
47 | QCopTransferItem(); | 50 | QCopTransferItem(); |
48 | 51 | ||
49 | bool sendMessageToTarget(const QString& uid, const QString& param1 = QString::null, const QString& param2 = QString::null, const QString& param3 = QString::null); | 52 | bool sendMessageToTarget(const QString& uid, const QString& param1 = QString::null, const QString& param2 = QString::null, const QString& param3 = QString::null); |
50 | 53 | ||
51 | void setSourceChannel(const QString& sourceChannel); | 54 | void setSourceChannel(const QString& sourceChannel); |
52 | 55 | ||
53 | virtual bool appMessage( const QCString& msg, const QByteArray& data ); | 56 | virtual bool appMessage( const Q3CString& msg, const QByteArray& data ); |
54 | 57 | ||
55 | 58 | ||
56 | signals: | 59 | signals: |
57 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid); | 60 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid); |
58 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid, const QString& param1); | 61 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid, const QString& param1); |
59 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid, const QString& param1, const QString& param2); | 62 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid, const QString& param1, const QString& param2); |
60 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid, const QString& param1, const QString& param2, const QString& param3); | 63 | void receivedMessageFromSource(const QString& sourceChannel, const QString& uid, const QString& param1, const QString& param2, const QString& param3); |
61 | 64 | ||
62 | public: | 65 | public: |
63 | int _usedSourceParameters; | 66 | int _usedSourceParameters; |
64 | QString _sourceChannel; | 67 | QString _sourceChannel; |
65 | QString _sourceMessage; | 68 | QString _sourceMessage; |
@@ -74,46 +77,46 @@ class QCopTransferItem : public QObject | |||
74 | * | 77 | * |
75 | ********************************************************************************/ | 78 | ********************************************************************************/ |
76 | 79 | ||
77 | class QCopMapTransferItem : public QCopTransferItem | 80 | class QCopMapTransferItem : public QCopTransferItem |
78 | { | 81 | { |
79 | Q_OBJECT | 82 | Q_OBJECT |
80 | public: | 83 | public: |
81 | QCopMapTransferItem(int usedSourceParameters, const QString& sourceMessage, const QString& targetChannel, const QString& targetMessage); | 84 | QCopMapTransferItem(int usedSourceParameters, const QString& sourceMessage, const QString& targetChannel, const QString& targetMessage); |
82 | 85 | ||
83 | bool sendMessageToSource(const QString& uid, const QMap<QString,QString>& nameEmailMap); | 86 | bool sendMessageToSource(const QString& uid, const QMap<QString,QString>& nameEmailMap); |
84 | 87 | ||
85 | 88 | ||
86 | virtual bool appMessage( const QCString& msg, const QByteArray& data ); | 89 | virtual bool appMessage( const Q3CString& msg, const QByteArray& data ); |
87 | 90 | ||
88 | 91 | ||
89 | signals: | 92 | signals: |
90 | void receivedMessageFromTarget(const QString& uid, const QMap<QString,QString>& nameEmailMap); | 93 | void receivedMessageFromTarget(const QString& uid, const QMap<QString,QString>& nameEmailMap); |
91 | 94 | ||
92 | }; | 95 | }; |
93 | 96 | ||
94 | /********************************************************************************* | 97 | /********************************************************************************* |
95 | * | 98 | * |
96 | ********************************************************************************/ | 99 | ********************************************************************************/ |
97 | 100 | ||
98 | class QCopListTransferItem : public QCopTransferItem | 101 | class QCopListTransferItem : public QCopTransferItem |
99 | { | 102 | { |
100 | Q_OBJECT | 103 | Q_OBJECT |
101 | public: | 104 | public: |
102 | QCopListTransferItem(int usedSourceParameters, const QString& sourceMessage, const QString& targetChannel, const QString& targetMessage); | 105 | QCopListTransferItem(int usedSourceParameters, const QString& sourceMessage, const QString& targetChannel, const QString& targetMessage); |
103 | ~QCopListTransferItem(); | 106 | ~QCopListTransferItem(); |
104 | bool sendMessageToSource(const QString& uid, const QStringList& list1, const QStringList& list2, const QStringList& list3, const QStringList& list4, const QStringList& list5, const QStringList& list6); | 107 | bool sendMessageToSource(const QString& uid, const QStringList& list1, const QStringList& list2, const QStringList& list3, const QStringList& list4, const QStringList& list5, const QStringList& list6); |
105 | 108 | ||
106 | 109 | ||
107 | virtual bool appMessage( const QCString& msg, const QByteArray& data ); | 110 | virtual bool appMessage( const Q3CString& msg, const QByteArray& data ); |
108 | 111 | ||
109 | 112 | ||
110 | signals: | 113 | signals: |
111 | void receivedMessageFromTarget(const QString& uid, const QStringList& list1, const QStringList& list2, const QStringList& list3, const QStringList& list4 , const QStringList& list5, const QStringList& list6); | 114 | void receivedMessageFromTarget(const QString& uid, const QStringList& list1, const QStringList& list2, const QStringList& list3, const QStringList& list4 , const QStringList& list5, const QStringList& list6); |
112 | 115 | ||
113 | }; | 116 | }; |
114 | 117 | ||
115 | /********************************************************************************* | 118 | /********************************************************************************* |
116 | * | 119 | * |
117 | ********************************************************************************/ | 120 | ********************************************************************************/ |
118 | 121 | ||
119 | 122 | ||
@@ -216,29 +219,29 @@ class ExternalAppHandler : public QObject | |||
216 | 219 | ||
217 | 220 | ||
218 | bool requestBirthdayListFromKAPI(const QString& sourceChannel, const QString& sessionuid); | 221 | bool requestBirthdayListFromKAPI(const QString& sourceChannel, const QString& sessionuid); |
219 | bool returnBirthdayListFromKAPI(const QString& sourceChannel, const QString& sessionuid, | 222 | bool returnBirthdayListFromKAPI(const QString& sourceChannel, const QString& sessionuid, |
220 | const QStringList& birthdayList, const QStringList& anniversaryList, | 223 | const QStringList& birthdayList, const QStringList& anniversaryList, |
221 | const QStringList& realNameList, const QStringList& emailList, | 224 | const QStringList& realNameList, const QStringList& emailList, |
222 | const QStringList& assembledNameList, const QStringList& uidList); | 225 | const QStringList& assembledNameList, const QStringList& uidList); |
223 | 226 | ||
224 | 227 | ||
225 | //loadConfig clears the cache and checks again if the applications are available or not | 228 | //loadConfig clears the cache and checks again if the applications are available or not |
226 | void loadConfig(); | 229 | void loadConfig(); |
227 | 230 | ||
228 | QList<DefaultAppItem> getAvailableDefaultItems(Types); | 231 | Q3PtrList<DefaultAppItem> getAvailableDefaultItems(Types); |
229 | DefaultAppItem* getDefaultItem(Types, int); | 232 | DefaultAppItem* getDefaultItem(Types, int); |
230 | 233 | ||
231 | public slots: | 234 | public slots: |
232 | void appMessage( const QCString& msg, const QByteArray& data ); | 235 | void appMessage( const Q3CString& msg, const QByteArray& data ); |
233 | 236 | ||
234 | 237 | ||
235 | signals: | 238 | signals: |
236 | void callContactdialog(); | 239 | void callContactdialog(); |
237 | void nextView(); | 240 | void nextView(); |
238 | void doRingSync(); | 241 | void doRingSync(); |
239 | // Emmitted when the target app receives a request from the source app | 242 | // Emmitted when the target app receives a request from the source app |
240 | void requestForNameEmailUidList(const QString& sourceChannel, const QString& uid); | 243 | void requestForNameEmailUidList(const QString& sourceChannel, const QString& uid); |
241 | 244 | ||
242 | // Emitted when the source app recieves a list of name/email pairs (=addresses) from another target app. Usually Ka/Pi | 245 | // Emitted when the source app recieves a list of name/email pairs (=addresses) from another target app. Usually Ka/Pi |
243 | // The first parameter is a uniqueid. It can be used to identify the event | 246 | // The first parameter is a uniqueid. It can be used to identify the event |
244 | void receivedNameEmailUidListEvent(const QString& uid, const QStringList& nameList, const QStringList& emailList, const QStringList& uidList); | 247 | void receivedNameEmailUidListEvent(const QString& uid, const QStringList& nameList, const QStringList& emailList, const QStringList& uidList); |
@@ -253,25 +256,25 @@ class ExternalAppHandler : public QObject | |||
253 | void requestForBirthdayList(const QString& sourceChannel, const QString& uid); | 256 | void requestForBirthdayList(const QString& sourceChannel, const QString& uid); |
254 | 257 | ||
255 | // Emitted when the source app recieves a list of name/email pairs (=addresses) from another target app. Usually Ka/Pi | 258 | // Emitted when the source app recieves a list of name/email pairs (=addresses) from another target app. Usually Ka/Pi |
256 | // The first parameter is a uniqueid. It can be used to identify the event | 259 | // The first parameter is a uniqueid. It can be used to identify the event |
257 | void receivedBirthdayListEvent(const QString& uid, const QStringList& birthdayList, | 260 | void receivedBirthdayListEvent(const QString& uid, const QStringList& birthdayList, |
258 | const QStringList& anniversaryList, const QStringList& realNameList, | 261 | const QStringList& anniversaryList, const QStringList& realNameList, |
259 | const QStringList& emailList, const QStringList& assembledNameList, | 262 | const QStringList& emailList, const QStringList& assembledNameList, |
260 | const QStringList& uidList); | 263 | const QStringList& uidList); |
261 | 264 | ||
262 | 265 | ||
263 | private: | 266 | private: |
264 | ExternalAppHandler(); | 267 | ExternalAppHandler(); |
265 | QList<DefaultAppItem> mDefaultItems; | 268 | Q3PtrList<DefaultAppItem> mDefaultItems; |
266 | 269 | ||
267 | Availability mEmailAppAvailable; | 270 | Availability mEmailAppAvailable; |
268 | Availability mPhoneAppAvailable; | 271 | Availability mPhoneAppAvailable; |
269 | Availability mFaxAppAvailable; | 272 | Availability mFaxAppAvailable; |
270 | Availability mSMSAppAvailable; | 273 | Availability mSMSAppAvailable; |
271 | Availability mPagerAppAvailable; | 274 | Availability mPagerAppAvailable; |
272 | Availability mSIPAppAvailable; | 275 | Availability mSIPAppAvailable; |
273 | 276 | ||
274 | QCopListTransferItem* mNameEmailUidListFromKAPITransfer; | 277 | QCopListTransferItem* mNameEmailUidListFromKAPITransfer; |
275 | QCopListTransferItem* mFindByEmailFromKAPITransfer; | 278 | QCopListTransferItem* mFindByEmailFromKAPITransfer; |
276 | QCopTransferItem* mDisplayDetails; | 279 | QCopTransferItem* mDisplayDetails; |
277 | QCopListTransferItem* mBirthdayListFromKAPITransfer; | 280 | QCopListTransferItem* mBirthdayListFromKAPITransfer; |