simpledatamodeladapter/src/presencepluginauthorization.cpp
branchRCL_3
changeset 8 b4758b4b2d20
parent 6 aca99fb8a3dd
--- a/simpledatamodeladapter/src/presencepluginauthorization.cpp	Wed Mar 31 22:15:41 2010 +0300
+++ b/simpledatamodeladapter/src/presencepluginauthorization.cpp	Wed Apr 14 16:22:17 2010 +0300
@@ -509,8 +509,22 @@
                 identity->SetIdentityL( iPresIdentity->Des() ); 
                 iConnObs.WatcherHandlerL()->DoPerformSubscribePresentityPresenceL( *identity, iStatus );
                 CleanupStack::PopAndDestroy( ); //identity 
+                iAuthState = EStateSubscribe;
+                SetActive();
+                }
+                break;
+                
+            case EStateSubscribe:
+                {
+                DP_SDA( "CPresencePluginAuthorization::RunL -UnBlock completed" ); 
+                HBufC* withoutPrefix = iPresenceData->RemovePrefixLC( *iPresIdentity );
+                iPresenceData->WriteStatusToCacheL( *withoutPrefix, 
+                    MPresenceBuddyInfo2::ENotAvailable,
+                    KInvisibleState(),
+                    KNullDesC() );
+                CleanupStack::PopAndDestroy( withoutPrefix );
                 iAuthState = EStateIdle;
-                SetActive();
+                CompleteXIMPReq( myStatus );
                 }
                 break;