|
1 /* |
|
2 * Copyright (c) 2002-2007 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: The remote sim view implementation |
|
15 * Version : %version: be1neux1#21.1.4 % |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 |
|
21 // INCLUDE FILES |
|
22 #include "CRemoteView.h" |
|
23 |
|
24 // From Virtual Phonebook |
|
25 #include "CRemoteStore.h" |
|
26 #include "VPbkSimStoreError.h" |
|
27 #include <MVPbkSimViewObserver.h> |
|
28 #include <VPbkSimServerOpCodes.h> |
|
29 #include <CVPbkSimContactBuf.h> |
|
30 #include <CVPbkAsyncOperation.h> |
|
31 #include <CVPbkAsyncCallback.h> |
|
32 #include <CVPbkSimFieldTypeFilter.h> |
|
33 #include <MVPbkSimViewFindObserver.h> |
|
34 #include <VPbkSimStoreTemplateFunctions.h> |
|
35 |
|
36 #include <s32mem.h> |
|
37 |
|
38 namespace VPbkSimStore { |
|
39 |
|
40 inline void SendEvent( |
|
41 RPointerArray<MVPbkSimViewObserver>& aObservers, |
|
42 void ( MVPbkSimViewObserver::*aEvent )( MVPbkSimCntView& ), |
|
43 CRemoteView& aThis ) |
|
44 { |
|
45 for ( TInt i = aObservers.Count() - 1; i >= 0; --i ) |
|
46 { |
|
47 ( aObservers[i]->*aEvent )( aThis ); |
|
48 } |
|
49 } |
|
50 |
|
51 inline void SendEvent( |
|
52 RPointerArray<MVPbkSimViewObserver>& aObservers, |
|
53 void ( MVPbkSimViewObserver::*aEvent )( MVPbkSimCntView&, TInt ), |
|
54 CRemoteView& aThis, |
|
55 TInt aParam ) |
|
56 { |
|
57 for ( TInt i = aObservers.Count() - 1; i >= 0; --i ) |
|
58 { |
|
59 ( aObservers[i]->*aEvent )( aThis, aParam ); |
|
60 } |
|
61 } |
|
62 |
|
63 inline void SendEvent( |
|
64 RPointerArray<MVPbkSimViewObserver>& aObservers, |
|
65 void ( MVPbkSimViewObserver::*aEvent ) |
|
66 ( MVPbkSimViewObserver::TEvent, TInt, TInt ), |
|
67 MVPbkSimViewObserver::TEvent aEventType, |
|
68 TInt aParam1, |
|
69 TInt aParam2 ) |
|
70 { |
|
71 for ( TInt i = aObservers.Count() - 1; i >= 0; --i ) |
|
72 { |
|
73 ( aObservers[i]->*aEvent )( aEventType, aParam1, aParam2 ); |
|
74 } |
|
75 } |
|
76 |
|
77 |
|
78 // ============================ MEMBER FUNCTIONS ============================ |
|
79 // -------------------------------------------------------------------------- |
|
80 // CRemoteView::CViewFindOperation::CViewFindOperation |
|
81 // C++ default constructor can NOT contain any code, that |
|
82 // might leave. |
|
83 // -------------------------------------------------------------------------- |
|
84 // |
|
85 CRemoteView::CViewFindOperation::CViewFindOperation( |
|
86 const MDesCArray& aFindStrings, |
|
87 MVPbkSimViewFindObserver& aObserver, |
|
88 RVPbkSimCntView& aSimCntViewSession, |
|
89 MVPbkSimCntView& aSimCntView ): |
|
90 CActive( EPriorityStandard ), |
|
91 iFindStrings( aFindStrings ), |
|
92 iObserver( aObserver ), |
|
93 iSimCntViewSession( aSimCntViewSession ), |
|
94 iSimCntView(aSimCntView), |
|
95 iSimMatchResultBufPtr( NULL, 0 ) |
|
96 { |
|
97 } |
|
98 |
|
99 // -------------------------------------------------------------------------- |
|
100 // CRemoteView::CViewFindOperation::ConstructL |
|
101 // Symbian 2nd phase constructor can leave. |
|
102 // -------------------------------------------------------------------------- |
|
103 // |
|
104 void CRemoteView::CViewFindOperation::ConstructL() |
|
105 { |
|
106 CActiveScheduler::Add( this ); |
|
107 } |
|
108 |
|
109 // -------------------------------------------------------------------------- |
|
110 // CRemoteView::CViewFindOperation::NewL |
|
111 // Two-phased constructor. |
|
112 // -------------------------------------------------------------------------- |
|
113 // |
|
114 CRemoteView::CViewFindOperation* CRemoteView::CViewFindOperation::NewL( |
|
115 const MDesCArray& aFindStrings, |
|
116 MVPbkSimViewFindObserver& aObserver, |
|
117 RVPbkSimCntView& aSimCntViewSession, |
|
118 MVPbkSimCntView& aSimCntView ) |
|
119 { |
|
120 CViewFindOperation* self = |
|
121 new( ELeave ) CViewFindOperation( aFindStrings, aObserver, |
|
122 aSimCntViewSession, aSimCntView ); |
|
123 CleanupStack::PushL( self ); |
|
124 self->ConstructL(); |
|
125 CleanupStack::Pop( self ); |
|
126 return self; |
|
127 } |
|
128 |
|
129 // Destructor |
|
130 CRemoteView::CViewFindOperation::~CViewFindOperation() |
|
131 { |
|
132 Cancel(); |
|
133 delete iSimMatchResultBuf; |
|
134 } |
|
135 |
|
136 // -------------------------------------------------------------------------- |
|
137 // CRemoteView::CViewFindOperation::ActivateL |
|
138 // -------------------------------------------------------------------------- |
|
139 // |
|
140 void CRemoteView::CViewFindOperation::ActivateL() |
|
141 { |
|
142 SetActive(); |
|
143 iSimCntViewSession.ContactMatchingPrefixL( iFindStrings, |
|
144 iResultBufferSize, |
|
145 iStatus ); |
|
146 } |
|
147 |
|
148 // -------------------------------------------------------------------------- |
|
149 // CRemoteView::CViewFindOperation::RunL |
|
150 // -------------------------------------------------------------------------- |
|
151 // |
|
152 void CRemoteView::CViewFindOperation::RunL() |
|
153 { |
|
154 RVPbkStreamedIntArray matchedIndexes; |
|
155 CleanupClosePushL( matchedIndexes ); |
|
156 |
|
157 TInt result = iStatus.Int(); |
|
158 switch ( result ) |
|
159 { |
|
160 case KErrNone: |
|
161 { |
|
162 //Delete old buffer |
|
163 if ( iSimMatchResultBuf ) |
|
164 { |
|
165 delete iSimMatchResultBuf; |
|
166 iSimMatchResultBuf = NULL; |
|
167 } |
|
168 |
|
169 //Create buffer |
|
170 iSimMatchResultBuf = HBufC8::NewL( iResultBufferSize ); |
|
171 iSimMatchResultBufPtr.Set( iSimMatchResultBuf->Des() ); |
|
172 |
|
173 //Get contact matching results |
|
174 iSimCntViewSession.ContactMatchingResultL( iSimMatchResultBufPtr ); |
|
175 |
|
176 //Unpack results |
|
177 RDesReadStream stream( iSimMatchResultBufPtr ); |
|
178 CleanupClosePushL( stream ); |
|
179 matchedIndexes.InternalizeL( stream ); |
|
180 CleanupStack::PopAndDestroy(); // stream |
|
181 |
|
182 iObserver.ViewFindCompleted( iSimCntView, matchedIndexes ); |
|
183 break; |
|
184 } |
|
185 default: |
|
186 { |
|
187 iObserver.ViewFindError( iSimCntView, result ); |
|
188 break; |
|
189 } |
|
190 } |
|
191 CleanupStack::PopAndDestroy(); // matchedIndexes |
|
192 } |
|
193 |
|
194 // -------------------------------------------------------------------------- |
|
195 // CRemoteView::CViewFindOperation::DoCancel |
|
196 // -------------------------------------------------------------------------- |
|
197 // |
|
198 void CRemoteView::CViewFindOperation::DoCancel() |
|
199 { |
|
200 iSimCntViewSession.CancelAsyncRequest( EVPbkSimSrvContactMatchingPrefix ); |
|
201 } |
|
202 |
|
203 // -------------------------------------------------------------------------- |
|
204 // CRemoteView::CViewFindOperation::RunError |
|
205 // -------------------------------------------------------------------------- |
|
206 // |
|
207 TInt CRemoteView::CViewFindOperation::RunError( TInt aError ) |
|
208 { |
|
209 iObserver.ViewFindError( iSimCntView, aError ); |
|
210 return KErrNone; |
|
211 } |
|
212 |
|
213 // -------------------------------------------------------------------------- |
|
214 // CRemoteView::CRemoteView |
|
215 // C++ default constructor can NOT contain any code, that |
|
216 // might leave. |
|
217 // -------------------------------------------------------------------------- |
|
218 // |
|
219 CRemoteView::CRemoteView( CRemoteStore& aStore, |
|
220 TVPbkSimViewConstructionPolicy aConstructionPolicy, |
|
221 CVPbkSimFieldTypeFilter* aFilter ) : |
|
222 CActive( EPriorityStandard ), |
|
223 iStore( aStore ), |
|
224 iConstructionPolicy( aConstructionPolicy ), |
|
225 iFilter( aFilter ) |
|
226 { |
|
227 } |
|
228 |
|
229 // -------------------------------------------------------------------------- |
|
230 // CRemoteView::~CRemoteView |
|
231 // Destructor |
|
232 // -------------------------------------------------------------------------- |
|
233 // |
|
234 CRemoteView::~CRemoteView() |
|
235 { |
|
236 delete iObserverOp; |
|
237 iObservers.Reset(); |
|
238 iSortOrder.Close(); |
|
239 iStore.RemoveObserver( *this ); |
|
240 Cancel(); |
|
241 delete iCurrentContact; |
|
242 iSimView.Close(); |
|
243 delete iViewName; |
|
244 delete iFilter; |
|
245 } |
|
246 |
|
247 // -------------------------------------------------------------------------- |
|
248 // CRemoteView::NewLC |
|
249 // Two-phased constructor. |
|
250 // -------------------------------------------------------------------------- |
|
251 // |
|
252 CRemoteView* CRemoteView::NewL( CRemoteStore& aStore, |
|
253 const RVPbkSimFieldTypeArray& aSortOrder, |
|
254 TVPbkSimViewConstructionPolicy aConstructionPolicy, |
|
255 const TDesC& aViewName, |
|
256 CVPbkSimFieldTypeFilter* aFilter ) |
|
257 { |
|
258 CRemoteView* self = |
|
259 new( ELeave ) CRemoteView( aStore, aConstructionPolicy, aFilter ); |
|
260 CleanupStack::PushL( self ); |
|
261 self->ConstructL( aSortOrder, aViewName ); |
|
262 CleanupStack::Pop( self ); |
|
263 return self; |
|
264 } |
|
265 |
|
266 // -------------------------------------------------------------------------- |
|
267 // CRemoteView::ConstructL |
|
268 // Symbian 2nd phase constructor can leave. |
|
269 // -------------------------------------------------------------------------- |
|
270 // |
|
271 void CRemoteView::ConstructL( const RVPbkSimFieldTypeArray& aSortOrder, |
|
272 const TDesC& aViewName ) |
|
273 { |
|
274 CActiveScheduler::Add( this ); |
|
275 SetSortOrderL( aSortOrder ); |
|
276 iViewName = aViewName.AllocL(); |
|
277 iCurrentContact = CVPbkSimContactBuf::NewL( iStore ); |
|
278 iStore.AddObserverL( *this ); |
|
279 iObserverOp = CVPbkAsyncObjectOperation<MVPbkSimViewObserver>::NewL(); |
|
280 } |
|
281 |
|
282 |
|
283 // -------------------------------------------------------------------------- |
|
284 // CRemoteView::RunL |
|
285 // -------------------------------------------------------------------------- |
|
286 // |
|
287 void CRemoteView::RunL() |
|
288 { |
|
289 if ( iStatus == KErrNone ) |
|
290 { |
|
291 switch ( iEventData.iEvent ) |
|
292 { |
|
293 case EVPbkSimViewOpen: |
|
294 { |
|
295 SendEvent(iObservers, &MVPbkSimViewObserver::ViewReady, *this); |
|
296 break; |
|
297 } |
|
298 case EVPbkSimViewNotAvailable: |
|
299 { |
|
300 SendEvent(iObservers, &MVPbkSimViewObserver::ViewNotAvailable, *this); |
|
301 break; |
|
302 } |
|
303 case EVPbkSimContactAdded: |
|
304 { |
|
305 if( iEventData.iData != KErrNotFound ) |
|
306 { |
|
307 SendEvent(iObservers, &MVPbkSimViewObserver::ViewContactEvent, |
|
308 MVPbkSimViewObserver::EContactAdded, |
|
309 iEventData.iData, iEventData.iOpData ); |
|
310 } |
|
311 break; |
|
312 } |
|
313 case EVPbkSimContactDeleted: |
|
314 { |
|
315 SendEvent(iObservers, &MVPbkSimViewObserver::ViewContactEvent, |
|
316 MVPbkSimViewObserver::EContactDeleted, |
|
317 iEventData.iData, iEventData.iOpData ); |
|
318 break; |
|
319 } |
|
320 case EVPbkSimViewError: |
|
321 { |
|
322 SendEvent(iObservers, &MVPbkSimViewObserver::ViewError, |
|
323 *this, iEventData.iOpData ); |
|
324 break; |
|
325 } |
|
326 case EVPbkSimUnknown: // FALLTHROUGH |
|
327 default: |
|
328 { |
|
329 __ASSERT_DEBUG( EFalse, VPbkSimStore::Panic( |
|
330 VPbkSimStore::EUnknownViewEventFromServer ) ); |
|
331 SendEvent(iObservers, &MVPbkSimViewObserver::ViewError, |
|
332 *this, KErrUnknown ); |
|
333 break; |
|
334 } |
|
335 } |
|
336 } |
|
337 else |
|
338 { |
|
339 SendEvent(iObservers, &MVPbkSimViewObserver::ViewError, |
|
340 *this, iStatus.Int() ); |
|
341 } |
|
342 |
|
343 ActivateViewNotification(); |
|
344 } |
|
345 |
|
346 // -------------------------------------------------------------------------- |
|
347 // CRemoteView::DoCancel |
|
348 // -------------------------------------------------------------------------- |
|
349 // |
|
350 void CRemoteView::DoCancel() |
|
351 { |
|
352 iSimView.CancelAsyncRequest( EVPbkSimSrvViewEventNotification ); |
|
353 } |
|
354 |
|
355 // -------------------------------------------------------------------------- |
|
356 // CRemoteView::Name |
|
357 // -------------------------------------------------------------------------- |
|
358 // |
|
359 const TDesC& CRemoteView::Name() const |
|
360 { |
|
361 return *iViewName; |
|
362 } |
|
363 |
|
364 // -------------------------------------------------------------------------- |
|
365 // CRemoteView::ParentStore |
|
366 // -------------------------------------------------------------------------- |
|
367 // |
|
368 MVPbkSimCntStore& CRemoteView::ParentStore() const |
|
369 { |
|
370 return iStore; |
|
371 } |
|
372 |
|
373 // -------------------------------------------------------------------------- |
|
374 // CRemoteView::OpenL |
|
375 // -------------------------------------------------------------------------- |
|
376 // |
|
377 void CRemoteView::OpenL( MVPbkSimViewObserver& aObserver ) |
|
378 { |
|
379 TInt index = iObservers.Find(&aObserver); |
|
380 __ASSERT_DEBUG( index == KErrNotFound, |
|
381 Panic( ERemoteViewObserverAlreadySet ) ); |
|
382 iObservers.AppendL(&aObserver); |
|
383 |
|
384 // Open view subsession only if the store has been opened |
|
385 // This is actually called only from CContactView::ConstructL so |
|
386 // it's called only once -> not need to make else-clause for async |
|
387 if ( iStore.IsOpen() && !iSimView.SubSessionHandle()) |
|
388 { |
|
389 iSimView.OpenL( iStore.StoreSession(), iSortOrder, iConstructionPolicy, |
|
390 *iViewName, iFilter ); |
|
391 ActivateViewNotification(); |
|
392 } |
|
393 else |
|
394 { |
|
395 // Complete with "View unavailable" event |
|
396 CVPbkAsyncObjectCallback<MVPbkSimViewObserver>* callback = |
|
397 VPbkEngUtils::CreateAsyncObjectCallbackLC( |
|
398 *this, |
|
399 &CRemoteView::DoViewUnavailableL, |
|
400 &CRemoteView::DoViewUnavailableError, |
|
401 aObserver ); |
|
402 |
|
403 iObserverOp->CallbackL( callback ); |
|
404 CleanupStack::Pop( callback ); // openCallback |
|
405 } |
|
406 } |
|
407 |
|
408 // -------------------------------------------------------------------------- |
|
409 // CRemoteView::Close |
|
410 // -------------------------------------------------------------------------- |
|
411 // |
|
412 void CRemoteView::Close( MVPbkSimViewObserver& aObserver ) |
|
413 { |
|
414 // Cancel the possible call back |
|
415 iObserverOp->CancelCallback( &aObserver ); |
|
416 |
|
417 // Remove from the observer list |
|
418 TInt index = iObservers.Find(&aObserver); |
|
419 if (index != KErrNotFound) |
|
420 { |
|
421 iObservers.Remove(index); |
|
422 } |
|
423 |
|
424 // If it was the last user then close the connection to the server. |
|
425 if (iObservers.Count() == 0) |
|
426 { |
|
427 Cancel(); |
|
428 iSimView.Close(); |
|
429 } |
|
430 } |
|
431 |
|
432 // -------------------------------------------------------------------------- |
|
433 // CRemoteView::CountL |
|
434 // -------------------------------------------------------------------------- |
|
435 // |
|
436 TInt CRemoteView::CountL() const |
|
437 { |
|
438 return iSimView.CountL(); |
|
439 } |
|
440 |
|
441 // -------------------------------------------------------------------------- |
|
442 // CRemoteView::ContactAtL |
|
443 // -------------------------------------------------------------------------- |
|
444 // |
|
445 MVPbkSimContact& CRemoteView::ContactAtL( TInt aIndex ) |
|
446 { |
|
447 iCurrentContact->SetL( iSimView.ContactAtL( aIndex ) ); |
|
448 return *iCurrentContact; |
|
449 } |
|
450 |
|
451 // -------------------------------------------------------------------------- |
|
452 // CRemoteView::ChangeSortOrderL |
|
453 // -------------------------------------------------------------------------- |
|
454 // |
|
455 void CRemoteView::ChangeSortOrderL( const RVPbkSimFieldTypeArray& aSortOrder ) |
|
456 { |
|
457 if ( iSimView.SubSessionHandle() ) |
|
458 { |
|
459 SetSortOrderL( aSortOrder ); |
|
460 iSimView.ChangeSortOrderL( aSortOrder ); |
|
461 } |
|
462 } |
|
463 |
|
464 // -------------------------------------------------------------------------- |
|
465 // CRemoteView::MapSimIndexToViewIndexL |
|
466 // -------------------------------------------------------------------------- |
|
467 // |
|
468 TInt CRemoteView::MapSimIndexToViewIndexL( TInt aSimIndex ) |
|
469 { |
|
470 return iSimView.FindViewIndexL( aSimIndex ); |
|
471 } |
|
472 |
|
473 // -------------------------------------------------------------------------- |
|
474 // CRemoteView::ContactMatchingPrefixL |
|
475 // -------------------------------------------------------------------------- |
|
476 // |
|
477 MVPbkSimStoreOperation* CRemoteView::ContactMatchingPrefixL( |
|
478 const MDesCArray& aFindStrings, |
|
479 MVPbkSimViewFindObserver& aObserver ) |
|
480 { |
|
481 CViewFindOperation* operation = CViewFindOperation::NewL( |
|
482 aFindStrings, aObserver, iSimView, *this ); |
|
483 operation->ActivateL(); |
|
484 return operation; |
|
485 } |
|
486 |
|
487 // -------------------------------------------------------------------------- |
|
488 // CRemoteView::SortOrderL |
|
489 // -------------------------------------------------------------------------- |
|
490 // |
|
491 const RVPbkSimFieldTypeArray& CRemoteView::SortOrderL() const |
|
492 { |
|
493 HBufC8* sortOrder = iSimView.SortOrderL(); |
|
494 CleanupStack::PushL( sortOrder ); |
|
495 RDesReadStream readStream( *sortOrder ); |
|
496 readStream.PushL(); |
|
497 iSortOrder.Reset(); |
|
498 readStream >> iSortOrder; |
|
499 CleanupStack::PopAndDestroy( &readStream ); |
|
500 CleanupStack::PopAndDestroy( sortOrder ); |
|
501 return iSortOrder; |
|
502 } |
|
503 |
|
504 // -------------------------------------------------------------------------- |
|
505 // CRemoteView::MapSimIndexToViewIndexL |
|
506 // -------------------------------------------------------------------------- |
|
507 // |
|
508 void CRemoteView::StoreReady( MVPbkSimCntStore& /*aStore*/ ) |
|
509 { |
|
510 if ( !iSimView.SubSessionHandle() ) |
|
511 { |
|
512 TRAPD( result, iSimView.OpenL( iStore.StoreSession(), iSortOrder, |
|
513 iConstructionPolicy, *iViewName, iFilter ) ); |
|
514 if (result != KErrNone) |
|
515 { |
|
516 SendEvent(iObservers, &MVPbkSimViewObserver::ViewError, |
|
517 *this, result ); |
|
518 } |
|
519 ActivateViewNotification(); |
|
520 // Cancel any ongoing "View unavailable" events |
|
521 iObserverOp->Purge(); |
|
522 } |
|
523 } |
|
524 |
|
525 // -------------------------------------------------------------------------- |
|
526 // CRemoteView::StoreError |
|
527 // -------------------------------------------------------------------------- |
|
528 // |
|
529 void CRemoteView::StoreError( MVPbkSimCntStore& /*aStore*/, TInt aError ) |
|
530 { |
|
531 // Cancel any ongoing view events |
|
532 iObserverOp->Purge(); |
|
533 SendEvent(iObservers, &MVPbkSimViewObserver::ViewError, |
|
534 *this, aError ); |
|
535 } |
|
536 |
|
537 // -------------------------------------------------------------------------- |
|
538 // CRemoteView::StoreNotAvailable |
|
539 // -------------------------------------------------------------------------- |
|
540 // |
|
541 void CRemoteView::StoreNotAvailable( MVPbkSimCntStore& /*aStore*/ ) |
|
542 { |
|
543 // Cancel any ongoing view events |
|
544 iObserverOp->Purge(); |
|
545 SendEvent(iObservers, &MVPbkSimViewObserver::ViewNotAvailable, *this); |
|
546 } |
|
547 |
|
548 // -------------------------------------------------------------------------- |
|
549 // CRemoteView::StoreNotAvailable |
|
550 // -------------------------------------------------------------------------- |
|
551 // |
|
552 void CRemoteView::StoreContactEvent( TEvent /*aEvent*/, TInt /*aSimIndex*/ ) |
|
553 { |
|
554 |
|
555 } |
|
556 |
|
557 // -------------------------------------------------------------------------- |
|
558 // CRemoteView::ActivateViewNotification |
|
559 // -------------------------------------------------------------------------- |
|
560 // |
|
561 void CRemoteView::ActivateViewNotification() |
|
562 { |
|
563 if ( !IsActive() && iSimView.SubSessionHandle() ) |
|
564 { |
|
565 iSimView.ListenToViewEvents( iStatus, iEventData ); |
|
566 SetActive(); |
|
567 } |
|
568 } |
|
569 |
|
570 // -------------------------------------------------------------------------- |
|
571 // CRemoteView::SetSortOrderL |
|
572 // -------------------------------------------------------------------------- |
|
573 // |
|
574 void CRemoteView::SetSortOrderL( const RVPbkSimFieldTypeArray& aSortOrder ) |
|
575 { |
|
576 iSortOrder.Reset(); |
|
577 const TInt count = aSortOrder.Count(); |
|
578 for ( TInt i = 0; i < count; ++i ) |
|
579 { |
|
580 iSortOrder.AppendL( aSortOrder[i] ); |
|
581 } |
|
582 } |
|
583 |
|
584 // -------------------------------------------------------------------------- |
|
585 // CRemoteView::IssueRequest |
|
586 // -------------------------------------------------------------------------- |
|
587 // |
|
588 void CRemoteView::IssueRequest( TInt aError ) |
|
589 { |
|
590 TRequestStatus* status = &iStatus; |
|
591 User::RequestComplete(status, aError); |
|
592 SetActive(); |
|
593 } |
|
594 |
|
595 // -------------------------------------------------------------------------- |
|
596 // CRemoteView::DoViewUnavailableL |
|
597 // -------------------------------------------------------------------------- |
|
598 // |
|
599 void CRemoteView::DoViewUnavailableL( MVPbkSimViewObserver& aObserver ) |
|
600 { |
|
601 aObserver.ViewNotAvailable( *this ); |
|
602 } |
|
603 |
|
604 // -------------------------------------------------------------------------- |
|
605 // CRemoteView::DoViewUnavailableError |
|
606 // -------------------------------------------------------------------------- |
|
607 // |
|
608 void CRemoteView::DoViewUnavailableError( MVPbkSimViewObserver& aObserver, |
|
609 TInt aError ) |
|
610 { |
|
611 aObserver.ViewError( *this, aError ); |
|
612 } |
|
613 } // namespace VPbkSimStore |
|
614 |
|
615 // End of File |