imservices/ossprotocoladaptation/src/waittimer.cpp
branchCompilerCompatibility
changeset 15 ca8de445a388
parent 0 e6b17d312c8b
equal deleted inserted replaced
14:e99acc9979f2 15:ca8de445a388
   728     				break;
   728     				break;
   729     				}
   729     				}
   730     			case ESearch_State_Finished:
   730     			case ESearch_State_Finished:
   731     				{
   731     				{
   732                     LOGGER ( TXT ( "CWaitTimer::ESearch_State_Finished" ) );
   732                     LOGGER ( TXT ( "CWaitTimer::ESearch_State_Finished" ) );
   733     				operationindex = ( FindOperationL ( iOpId, COssSendDataOperation::OperationId ) );
   733     				operationindex = ( FindOperationL ( iOpId, &COssSendDataOperation::OperationId ) );
   734     
   734     
   735     				if ( operationindex != KErrNotFound )
   735     				if ( operationindex != KErrNotFound )
   736     					{
   736     					{
   737     					LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   737     					LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   738     					iOperations[ operationindex ]->SetResponse ( rmsg ); //ownership of rmsg is transferred
   738     					iOperations[ operationindex ]->SetResponse ( rmsg ); //ownership of rmsg is transferred
   755     		            CleanupStack::PopAndDestroy( rmsg );
   755     		            CleanupStack::PopAndDestroy( rmsg );
   756     					}
   756     					}
   757     				else
   757     				else
   758     					{
   758     					{
   759     					LOGGER ( TXT ( "CWaitTimer::ESearch: ERROR !!" ) );
   759     					LOGGER ( TXT ( "CWaitTimer::ESearch: ERROR !!" ) );
   760     					operationindex = ( FindOperationL ( iOpId, COssSendDataOperation::OperationId ) );
   760     					operationindex = ( FindOperationL ( iOpId, &COssSendDataOperation::OperationId ) );
   761     					iOperations[ operationindex ]->SetResponse ( rmsg ); //ownership of rmsg is transferred
   761     					iOperations[ operationindex ]->SetResponse ( rmsg ); //ownership of rmsg is transferred
   762     				    iOperations[ operationindex ]->CompletedOperation ( KErrNotSupported );// for all errors
   762     				    iOperations[ operationindex ]->CompletedOperation ( KErrNotSupported );// for all errors
   763     				    CleanupStack::Pop( rmsg );
   763     				    CleanupStack::Pop( rmsg );
   764     				    // send  not supported, since the error mapping is  not done 	
   764     				    // send  not supported, since the error mapping is  not done 	
   765     					}	
   765     					}	
   767     				}
   767     				}
   768     			case ESearch_Get_Keys:
   768     			case ESearch_Get_Keys:
   769     				{
   769     				{
   770     				
   770     				
   771     				LOGGER ( TXT ( "CWaitTimer::ESearch_Get_Keys" ) );
   771     				LOGGER ( TXT ( "CWaitTimer::ESearch_Get_Keys" ) );
   772     				operationindex = ( FindOperationL ( iOpId, COssSendDataOperation::OperationId ) );
   772     				operationindex = ( FindOperationL ( iOpId, &COssSendDataOperation::OperationId ) );
   773     
   773     
   774     				if ( operationindex != KErrNotFound )
   774     				if ( operationindex != KErrNotFound )
   775     					{
   775     					{
   776     					LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   776     					LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   777     					iOperations[ operationindex ]->SetResponse ( rmsg ); //ownership of rmsg is transferred
   777     					iOperations[ operationindex ]->SetResponse ( rmsg ); //ownership of rmsg is transferred
   790     				break;	
   790     				break;	
   791     				}
   791     				}
   792 			case EUpdateOwnAvtar :	
   792 			case EUpdateOwnAvtar :	
   793 			    {
   793 			    {
   794                 LOGGER ( TXT ( "CWaitTimer::EUpdateOwnAvtar" ) );
   794                 LOGGER ( TXT ( "CWaitTimer::EUpdateOwnAvtar" ) );
   795                 operationindex = ( FindOperationL ( iOpId, COssSendDataOperation::OperationId ) );
   795                 operationindex = ( FindOperationL ( iOpId, &COssSendDataOperation::OperationId ) );
   796 
   796 
   797                 if ( operationindex != KErrNotFound )
   797                 if ( operationindex != KErrNotFound )
   798                     {
   798                     {
   799                     LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   799                     LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   800 
   800 
   805                 break;
   805                 break;
   806 			    }
   806 			    }
   807     			default:
   807     			default:
   808     					{
   808     					{
   809     					LOGGER ( TXT ( "CWaitTimer::default start" ) );
   809     					LOGGER ( TXT ( "CWaitTimer::default start" ) );
   810     					operationindex = ( FindOperationL ( iOpId, COssSendDataOperation::OperationId ) );
   810     					operationindex = ( FindOperationL ( iOpId, &COssSendDataOperation::OperationId ) );
   811     
   811     
   812     					if ( operationindex != KErrNotFound )
   812     					if ( operationindex != KErrNotFound )
   813     						{
   813     						{
   814     						LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   814     						LOGGER ( TXT ( "CWaitTimer::FindOperationL found" ) );
   815     
   815     
   989 			iSearchElements.Remove ( 0 );
   989 			iSearchElements.Remove ( 0 );
   990 			iSearchElements.Compress();
   990 			iSearchElements.Compress();
   991 			}
   991 			}
   992        	else 
   992        	else 
   993 	        {
   993 	        {
   994 	       	TInt x ( FindOperationL ( 6, COssSendDataOperation::OperationId ) );
   994 	       	TInt x ( FindOperationL ( 6, &COssSendDataOperation::OperationId ) );
   995 			if( x != -1)
   995 			if( x != -1)
   996 				{	// is operation completed?
   996 				{	// is operation completed?
   997 				TRequestStatus* status = iOperations[ x ]->Status();
   997 				TRequestStatus* status = iOperations[ x ]->Status();
   998 
   998 
   999 				if ( status && ( *status == KRequestPending ) )
   999 				if ( status && ( *status == KRequestPending ) )
  1021 		iContactChangeList.Remove ( 0 );
  1021 		iContactChangeList.Remove ( 0 );
  1022         iContactChangeList.Compress();
  1022         iContactChangeList.Compress();
  1023 		return buff;
  1023 		return buff;
  1024 		}			
  1024 		}			
  1025 	// try to find operation
  1025 	// try to find operation
  1026 	TInt x ( FindOperationL ( aTransId, COssSendDataOperation::OperationId ) );
  1026 	TInt x ( FindOperationL ( aTransId, &COssSendDataOperation::OperationId ) );
  1027 
  1027 
  1028 	// is operation completed?
  1028 	// is operation completed?
  1029 	TRequestStatus* status = iOperations[ x ]->Status();
  1029 	TRequestStatus* status = iOperations[ x ]->Status();
  1030 
  1030 
  1031 	if ( status && ( *status == KRequestPending ) )
  1031 	if ( status && ( *status == KRequestPending ) )