multimediacommscontroller/mmccinterface/src/mmcccodecdtmf.cpp
branchRCL_3
changeset 9 5bf83dc720b3
parent 0 1bce908db942
equal deleted inserted replaced
8:2a28ef775f15 9:5bf83dc720b3
    34 const TInt KMaxFmtpAttrLength( 50 );
    34 const TInt KMaxFmtpAttrLength( 50 );
    35 
    35 
    36 const TText8 KCharComma = ',';
    36 const TText8 KCharComma = ',';
    37 const TText8 KCharHyphen = '-';
    37 const TText8 KCharHyphen = '-';
    38 const TText8 KCharSpace = ' ';
    38 const TText8 KCharSpace = ' ';
       
    39 const TText8 KCharSemicolon = ';';
    39 
    40 
    40 
    41 
    41 
    42 
    42 
    43 
    43 // MACROS
    44 // MACROS
   382     
   383     
   383     TBool updated = EFalse;
   384     TBool updated = EFalse;
   384     
   385     
   385     if ( aFmtp.Length() > 0 )
   386     if ( aFmtp.Length() > 0 )
   386         {
   387         {
       
   388 		//the firt, process semicolon and get its left data
       
   389 		TBufC8<256> value(aFmtp);
       
   390 		TInt match = value.Locate( KCharSemicolon );
       
   391 		if( KErrNotFound != match )
       
   392 			{
       
   393 			value = value.Left( match );
       
   394 			}
   387         // white space is not allowed 
   395         // white space is not allowed 
   388         if ( aFmtp.Locate( KCharSpace ) >= 0 )
   396         if ( value.Locate( KCharSpace ) >= 0 )
   389             {
   397             {
   390             User::Leave( KErrArgument );  
   398             User::Leave( KErrArgument );  
   391             }
   399             }
   392            
   400            
   393         CPtrC8Array* tokens = TokenizeL( aFmtp, KCharComma );
   401         CPtrC8Array* tokens = TokenizeL( value, KCharComma );
   394         CleanupStack::PushL( tokens );
   402         CleanupStack::PushL( tokens );
   395         
   403         
   396         // Mask will be updated while parsing
   404         // Mask will be updated while parsing
   397         iBitrateMask = 0;
   405         iBitrateMask = 0;
   398         
   406