phonebookengines/VirtualPhonebook/VPbkCntModel/src/TContactFieldDataImpl.cpp
branchRCL_3
changeset 58 d4f567ce2e7c
parent 0 e686773b3f54
child 64 c1e8ba0c2b16
equal deleted inserted replaced
57:2666d9724c76 58:d4f567ce2e7c
   174             if ( !Validate(aUri, ETrue) )
   174             if ( !Validate(aUri, ETrue) )
   175                {
   175                {
   176                User::Leave(KErrNotSupported);
   176                User::Leave(KErrNotSupported);
   177                }
   177                }
   178             }
   178             }
   179         
   179         else // If it is an IMPP field
       
   180             {
       
   181             TInt pos = aUri.Find(KColon);
       
   182             // If the service name or the colon doesn't exist, let it leave the function.
       
   183             // e.g.:
       
   184             // (1) If the value is YAHOO:peterpan@yahoo.com, YAHOO is the service name
       
   185             // (2) If the value is :peterpan@yahoo.com, the service name is NULL
       
   186             // (3) If the value is peterpan@yahoo.com, neither the service name and the colon exists
       
   187             if( 0 == pos || KErrNotFound == pos )
       
   188                 {
       
   189                 User::Leave(KErrNotSupported);
       
   190                 }
       
   191             }
   180         }
   192         }
   181     iCntModelField->TextStorage()->SetTextL(aUri);
   193     iCntModelField->TextStorage()->SetTextL(aUri);
   182     }
   194     }
   183 
   195 
   184 // aScheme: scheme part of URI aText: rest of URI
   196 // aScheme: scheme part of URI aText: rest of URI