deviceupdatesui/deviceupdates/src/dmfotaview.cpp
changeset 43 88e14c3d4c4f
parent 38 2d078e09a2f4
child 47 d316aecb87fd
equal deleted inserted replaced
38:2d078e09a2f4 43:88e14c3d4c4f
   171             str = QString::fromUtf16(swversion.Ptr(), swversion.Length());
   171             str = QString::fromUtf16(swversion.Ptr(), swversion.Length());
   172             FormatList(val,str);
   172             FormatList(val,str);
   173             }
   173             }
   174 
   174 
   175     //Model
   175     //Model
       
   176     TBuf<100> phoneName;
       
   177     TInt error = SysVersionInfo::GetVersionInfo(SysVersionInfo::EModelVersion, phoneName);
       
   178     if (error==KErrNone)
       
   179     {
       
   180     
       
   181     //phoneName.Copy( telid.iModel );
       
   182     //imei.Copy(telid.iSerialNumber);
       
   183     if( phoneName.Length()>0 )
       
   184         {
       
   185         val = hbTrId("txt_device_update_dblist_model");
       
   186         str = QString::fromUtf16(phoneName.Ptr(), phoneName.Length());
       
   187         FormatList(val,str);
       
   188         }
       
   189     }
   176     RTelServer telServer;
   190     RTelServer telServer;
   177     User::LeaveIfError( telServer.Connect() );
   191     User::LeaveIfError( telServer.Connect() );
   178     RTelServer::TPhoneInfo teleinfo;
   192     RTelServer::TPhoneInfo teleinfo;
   179     User::LeaveIfError( telServer.GetPhoneInfo( 0, teleinfo ) );
   193     User::LeaveIfError( telServer.GetPhoneInfo( 0, teleinfo ) );
   180     RMobilePhone phone;
   194     RMobilePhone phone;
   187     phone.GetPhoneId( status, telid );
   201     phone.GetPhoneId( status, telid );
   188     User::WaitForRequest( status );
   202     User::WaitForRequest( status );
   189     TBuf <50> imei;
   203     TBuf <50> imei;
   190     if (status==KErrNone)
   204     if (status==KErrNone)
   191     {
   205     {
   192     TBuf<100> phoneName;
       
   193     phoneName.Copy( telid.iModel );
       
   194     imei.Copy(telid.iSerialNumber);
   206     imei.Copy(telid.iSerialNumber);
   195     if( phoneName.Length()>0 )
       
   196         {
       
   197         val = hbTrId("txt_device_update_dblist_model");
       
   198         str = QString::fromUtf16(phoneName.Ptr(), phoneName.Length());
       
   199         FormatList(val,str);
       
   200         }
       
   201     }
   207     }
   202     phone.Close();
   208     phone.Close();
       
   209     
   203     telServer.Close();
   210     telServer.Close();
   204 
   211 
   205     //type
   212     //type
   206     if(typedesignator.Length()>0)
   213     if(typedesignator.Length()>0)
   207         {
   214         {
   225                 }
   232                 }
   226           if(runtimesupport)
   233           if(runtimesupport)
   227           { */
   234           { */
   228          TBuf<KSysUtilVersionTextLength> productcode;
   235          TBuf<KSysUtilVersionTextLength> productcode;
   229          productcode.Zero();
   236          productcode.Zero();
   230          TInt error = SysVersionInfo::GetVersionInfo(SysVersionInfo::EProductCode, productcode);
   237          error = SysVersionInfo::GetVersionInfo(SysVersionInfo::EProductCode, productcode);
   231          if(error ==KErrNone )
   238          if(error ==KErrNone )
   232          {            
   239          {            
   233              if( productcode.Length()>0 )
   240              if( productcode.Length()>0 )
   234              {        
   241              {        
   235              val = hbTrId("txt_device_update_dblist_product_code");
   242              val = hbTrId("txt_device_update_dblist_product_code");