bearermanagement/mpm/src/mpmconfirmdlgstarting.cpp
changeset 32 5c4486441ae6
parent 20 9c97ad6591ae
child 41 bbb64eb3bdee
equal deleted inserted replaced
31:c16e04725da3 32:5c4486441ae6
   201 
   201 
   202 void CMPMConfirmDlgStarting::UserSelectedConnectThisTime()
   202 void CMPMConfirmDlgStarting::UserSelectedConnectThisTime()
   203     {
   203     {
   204     MPMLOGSTRING2( "CMPMConfirmDlgStarting<0x%x>::UserSelectedConnectThisTime", iConnId )
   204     MPMLOGSTRING2( "CMPMConfirmDlgStarting<0x%x>::UserSelectedConnectThisTime", iConnId )
   205     
   205     
   206     TBool wlanNeeded( EFalse );
   206     TBool isWlan( EFalse );
   207     TRAPD( err, wlanNeeded = iIapSelection.StartWlanQueryIfNeededL( iIAP ) )
   207     TRAPD( err, isWlan = iIapSelection.IsIapWlanL( iIAP ) )
   208     if( err == KErrNone )
   208     if( err == KErrNone )
   209         {
   209         {
   210         if( !wlanNeeded )
   210         if( !isWlan )
   211             {
   211             {
   212             if ( iIapState == CMPMIapSelection::EImplicitConnection )
   212             if ( iIapState == CMPMIapSelection::EImplicitConnection )
   213                 {
   213                 {
   214                 TRAP( err, iIapSelection.CompleteImplicitConnectionL() )
   214                 TRAP( err, iIapSelection.CompleteImplicitConnectionL() )
   215                 
   215                 
   226                                             iSnapId, 
   226                                             iSnapId, 
   227                                             iIAP, 
   227                                             iIAP, 
   228                                             EStarting,
   228                                             EStarting,
   229                                             iSession );
   229                                             iSession );
   230 
   230 
   231                 // Complete the ChooseBestIAP message with 
       
   232                 // KErrNone if user selected yes.
       
   233                 // 
       
   234                 MPMLOGSTRING2( "CMPMConfirmDlgStarting<0x%x>::UserSelectedConnectThisTime:\
   231                 MPMLOGSTRING2( "CMPMConfirmDlgStarting<0x%x>::UserSelectedConnectThisTime:\
   235 Complete KErrNone", iConnId )
   232 Complete KErrNone", iConnId )
   236                 iIapSelection.ChooseIapComplete( KErrNone, &iPref );                        
   233                 iIapSelection.ChooseIapComplete( KErrNone, &iPref );                        
   237                 }
   234                 }
   238             }
   235             }
   263             genConnSettings.iCellularDataUsageHome = ECmCellularDataUsageAutomatic;        
   260             genConnSettings.iCellularDataUsageHome = ECmCellularDataUsageAutomatic;        
   264             TRAP_IGNORE(iServer.CommsDatAccess()->WriteGenConnSettingsL( genConnSettings )); 
   261             TRAP_IGNORE(iServer.CommsDatAccess()->WriteGenConnSettingsL( genConnSettings )); 
   265             }
   262             }
   266         } 
   263         } 
   267     
   264     
   268     TBool wlanNeeded( EFalse );
   265     TBool isWlan( EFalse );
   269     TRAPD( err, wlanNeeded = iIapSelection.StartWlanQueryIfNeededL( iIAP ) )
   266     TRAPD( err, isWlan = iIapSelection.IsIapWlanL( iIAP ) )
   270     if( err == KErrNone )
   267     if( err == KErrNone )
   271         {
   268         {
   272         if( !wlanNeeded )
   269         if( !isWlan )
   273             {
   270             {
   274             if ( iIapState == CMPMIapSelection::EImplicitConnection )
   271             if ( iIapState == CMPMIapSelection::EImplicitConnection )
   275                 {
   272                 {
   276                 TRAP( err, iIapSelection.CompleteImplicitConnectionL() )
   273                 TRAP( err, iIapSelection.CompleteImplicitConnectionL() )
   277                 
   274                 
   288                                             iSnapId, 
   285                                             iSnapId, 
   289                                             iIAP, 
   286                                             iIAP, 
   290                                             EStarting,
   287                                             EStarting,
   291                                             iSession );
   288                                             iSession );
   292 
   289 
   293                  // Complete the ChooseBestIAP message with 
       
   294                  // KErrNone if user selected yes.
       
   295                  // 
   290                  // 
   296                  MPMLOGSTRING2( "CMPMConfirmDlgStarting<0x%x>::UserSelectedConnectAutomatically:\
   291                  MPMLOGSTRING2( "CMPMConfirmDlgStarting<0x%x>::UserSelectedConnectAutomatically:\
   297 Complete KErrNone", iConnId )
   292 Complete KErrNone", iConnId )
   298                 iIapSelection.ChooseIapComplete( KErrNone, &iPref );    
   293                 iIapSelection.ChooseIapComplete( KErrNone, &iPref );    
   299                 }
   294                 }