62 { |
62 { |
63 private: |
63 private: |
64 |
64 |
65 enum TState |
65 enum TState |
66 { |
66 { |
67 EMainContactRetrieving, |
67 // EInitialState -> EMainContactRetrieved |
68 ExSPLinksRetrieving, |
68 EInitialState, |
69 ExSPContactsRetrieving, |
69 // EMainContactRetrieved -> ExSPLinksRetrieved |
70 EWaitForPresenceIcons, |
70 // EMainContactRetrieved -> EAddressSelectDone |
71 EDialogWaitsUserInput |
71 EMainContactRetrieved, |
|
72 // ExSPLinksRetrieved -> ExSPContactRetrieved |
|
73 // ExSPLinksRetrieved -> EPresenceIconInfoRetrieved |
|
74 // ExSPLinksRetrieved -> EAddressSelectDone |
|
75 ExSPLinksRetrieved, |
|
76 // ExSPContactRetrieved -> ExSPContactRetrieved |
|
77 // ExSPContactRetrieved -> ExSPContactsRetrieved |
|
78 // ExSPContactRetrieved -> EAddressSelectDone |
|
79 ExSPContactRetrieved, |
|
80 // ExSPContactsRetrieved -> EPresenceIconInfoRetrieved |
|
81 // ExSPContactsRetrieved -> EAddressSelectDone |
|
82 ExSPContactsRetrieved, |
|
83 // EPresenceIconInfoRetrieved -> EPresenceIconRetrieved |
|
84 // EPresenceIconInfoRetrieved -> EAddressSelectDone |
|
85 EPresenceIconInfoRetrieved, |
|
86 // EPresenceIconRetrieved -> EPresenceIconsRetrieved |
|
87 // EPresenceIconRetrieved -> EAddressSelectDone |
|
88 EPresenceIconRetrieved, |
|
89 // EPresenceIconsRetrieved -> EAddressSelectDone |
|
90 EPresenceIconsRetrieved, |
|
91 // EAddressSelectDone -> EAddressSelectError |
|
92 EAddressSelectDone, |
|
93 EAddressSelectError |
72 }; |
94 }; |
73 |
95 |
74 public: // Construction |
96 public: // Construction |
75 |
97 |
76 /** |
98 /** |
176 CVPbkFieldTypeSelector& aFieldTypeSelector, |
198 CVPbkFieldTypeSelector& aFieldTypeSelector, |
177 VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector |
199 VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector |
178 aCommSelector ); |
200 aCommSelector ); |
179 void ConstructL( |
201 void ConstructL( |
180 const MVPbkContactLink& aContactLink ); |
202 const MVPbkContactLink& aContactLink ); |
|
203 void HandleReceiveIconInfosL( |
|
204 const TDesC8& aPackedLink, |
|
205 RPointerArray <MContactPresenceInfo>& aInfoArray, |
|
206 TInt aOpId ); |
|
207 void RetrieveContact(); |
181 void RetrieveContactL(); |
208 void RetrieveContactL(); |
|
209 void DoSelectAddresses(); |
182 void DoSelectAddressesL(); |
210 void DoSelectAddressesL(); |
183 TInt CorrectRSK( |
211 TInt CorrectRSK( |
184 TInt aAddressSelectResourceId ); |
212 TInt aAddressSelectResourceId ); |
185 void AppendResultL( |
213 void AppendResultL( |
186 const MVPbkStoreContactField* aField ); |
214 const MVPbkStoreContactField* aField ); |
187 void GetImppFieldDataL(CDesC16ArrayFlat & aXspIdArray, |
215 void GetImppFieldDataL(CDesC16ArrayFlat & aXspIdArray, |
188 MVPbkStoreContact& aContact ); |
216 MVPbkStoreContact& aContact ); |
189 void FilterXspContactsL(); |
217 void FilterXspContactsL(); |
190 TBool IsMatchL( MVPbkStoreContact& aXspContact, |
218 TBool IsMatchL( MVPbkStoreContact& aXspContact, |
191 MVPbkStoreContact& aStoreContact ); |
219 MVPbkStoreContact& aStoreContact ); |
|
220 void StartLoadingxSPContactLinks(); |
|
221 void StartLoadingxSPContactLinksL(); |
|
222 void StartLoadingxSPContacts( MVPbkContactLinkArray& aArray ); |
|
223 void StartLoadingxSPContactsL( MVPbkContactLinkArray& aArray ); |
|
224 void StartLoadingPresenceIconInfo(); |
|
225 void StartLoadingPresenceIconInfoL(); |
|
226 TInt NumOfAddressesL( MVPbkStoreContact& aStoreContact ); |
|
227 TInt NumOfAddressesL(); |
|
228 void GetPresenceInfoL(); |
192 |
229 |
193 private: // Data |
230 private: // Data |
194 /// Ref: Observer |
231 /// Ref: Observer |
195 MPbk2ServicePhaseObserver& iObserver; |
232 MPbk2ServicePhaseObserver& iObserver; |
196 /// Own: Contact links |
233 /// Own: Contact links |
231 HBufC* iFieldContent; |
268 HBufC* iFieldContent; |
232 /// Own: contact presence manager |
269 /// Own: contact presence manager |
233 MContactPresence* iContactPresence; |
270 MContactPresence* iContactPresence; |
234 /// Own: array of presence icons |
271 /// Own: array of presence icons |
235 RPointerArray<CPbk2PresenceIconInfo> iPresenceIconArray; |
272 RPointerArray<CPbk2PresenceIconInfo> iPresenceIconArray; |
236 /// Own: ETrue, if presence icon has been retrieved |
|
237 TBool iPresenceIconsRetrieved; |
|
238 /// Own: ETrue, if contact has been retrieved |
|
239 TBool iContactRetrieved; |
|
240 /// Own: Communication method |
273 /// Own: Communication method |
241 VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector iCommMethod; |
274 VPbkFieldTypeSelectorFactory::TVPbkContactActionTypeSelector iCommMethod; |
242 }; |
275 }; |
243 |
276 |
244 #endif // CPBK2COMMADDRESSSELECTPHASE_H |
277 #endif // CPBK2COMMADDRESSSELECTPHASE_H |