diff -r ed1e38b404e5 -r 6134b5029079 convergedconnectionhandler/cchclientapi/src/cchserviceimpl.cpp --- a/convergedconnectionhandler/cchclientapi/src/cchserviceimpl.cpp Wed Mar 31 21:20:05 2010 +0300 +++ b/convergedconnectionhandler/cchclientapi/src/cchserviceimpl.cpp Wed Apr 14 15:49:55 2010 +0300 @@ -136,10 +136,29 @@ TInt CCchServiceImpl::Enable( TCCHSubserviceType aType ) { CCHLOGSTRING( "CCchServiceImpl::Enable: IN" ); - - iAsynchroniser->Enable(aType); + TInt error = KErrNone; + if (iCch.ConnectivityDialogsAllowed()) + { + CCHLOGSTRING( "CCchServiceImpl::Enable: Async mode" ); + iAsynchroniser->Enable(aType); + } + else + { + CCHLOGSTRING( "CCchServiceImpl::Enable: Sync mode" ); + TServiceSelection selection( iServiceId, aType ); + TRequestStatus status = KErrNone; + iCch.CchClient().EnableService( selection, status, EFalse ); + + //even the cchclient api seems to be asynchronous, + //this method is completed immediately + User::WaitForRequest( status ); + error = status.Int(); + } + + CCHLOGSTRING2( " CCchServiceImpl::Enable: return %d", error ); + CCHLOGSTRING( "CCchServiceImpl::Enable: OUT" ); - return KErrNone; + return error; } // ---------------------------------------------------------------------------