phonebookui/pbkcommonui/src/cnteditviewitembuilder.cpp
changeset 40 b46a585f6909
parent 37 fd64c38c277d
child 46 efe85016a067
equal deleted inserted replaced
37:fd64c38c277d 40:b46a585f6909
    17 #include "cnteditviewitembuilder.h"
    17 #include "cnteditviewitembuilder.h"
    18 #include "cnteditviewlistmodel.h"
    18 #include "cnteditviewlistmodel.h"
    19 #include "cnteditviewdetailitem.h"
    19 #include "cnteditviewdetailitem.h"
    20 #include "cntviewparams.h"
    20 #include "cntviewparams.h"
    21 #include "cntstringmapper.h"
    21 #include "cntstringmapper.h"
       
    22 #include <hbnumbergrouping.h>
    22 
    23 
    23 CntEditViewItemBuilder::CntEditViewItemBuilder() :
    24 CntEditViewItemBuilder::CntEditViewItemBuilder() :
    24 mMap( new CntStringMapper() )
    25 mMap( new CntStringMapper() )
    25 {    
    26 {    
    26 }
    27 }
    61                     QContactPhoneNumber::FieldNumber,
    62                     QContactPhoneNumber::FieldNumber,
    62                     phoneNumberEditorView);
    63                     phoneNumberEditorView);
    63             
    64             
    64             detailItem->addIcon( mMap->getContactEditorIconString(subtype, context) );
    65             detailItem->addIcon( mMap->getContactEditorIconString(subtype, context) );
    65             detailItem->addText( mMap->getContactEditorLocString(subtype, context) );
    66             detailItem->addText( mMap->getContactEditorLocString(subtype, context) );
    66             detailItem->addText( number.number() );
    67             /*
       
    68              * Internationalization support, activate the following code 
       
    69              * when support available from Orbit
       
    70              */
       
    71             //detailItem->addText( HbNumberGrouping::formatPhoneNumber(number.number())); 
       
    72             detailItem->addText( number.number());
    67             list.append( detailItem );
    73             list.append( detailItem );
    68             }
    74             }
    69         }
    75         }
    70     }
    76     }
    71     
    77     
    93                     list.append( detailItem );
    99                     list.append( detailItem );
    94                 }
   100                 }
    95                 else if ( subtype == QContactOnlineAccount::SubTypeSipVoip )
   101                 else if ( subtype == QContactOnlineAccount::SubTypeSipVoip )
    96                 {
   102                 {
    97                     if ( context == QContactOnlineAccount::ContextHome )
   103                     if ( context == QContactOnlineAccount::ContextHome )
       
   104                         detailItem->addText( hbTrId("txt_phob_formlabel_internet_telephone_home") );
       
   105                     else if ( context == QContactOnlineAccount::ContextWork )
       
   106                         detailItem->addText( hbTrId("txt_phob_formlabel_internet_telephone_work") );
       
   107                     else
    98                         detailItem->addText( hbTrId("txt_phob_formlabel_internet_telephone") );
   108                         detailItem->addText( hbTrId("txt_phob_formlabel_internet_telephone") );
    99                     else if ( context == QContactOnlineAccount::ContextWork )
       
   100                         detailItem->addText( hbTrId("txt_phob_formlabel_internet_telephone_home") );
       
   101                     else
       
   102                         detailItem->addText( hbTrId("txt_phob_formlabel_internet_telephone_work") );
       
   103                     
   109                     
   104                     detailItem->addText( number.accountUri() );
   110                     detailItem->addText( number.accountUri() );
   105                     list.append( detailItem );
   111                     list.append( detailItem );
   106                 }
   112                 }
   107                 else
   113                 else