wlanutilities/wlansniffer/aiplugin/src/wsfaicontroller.cpp
changeset 3 ff3b37722600
parent 2 6e4b6261703d
child 10 dff6ebfd236f
equal deleted inserted replaced
2:6e4b6261703d 3:ff3b37722600
   549 
   549 
   550         passedIap = cmmanager.EasyWlanIdL();
   550         passedIap = cmmanager.EasyWlanIdL();
   551 
   551 
   552         CleanupStack::PopAndDestroy( &cmmanager );
   552         CleanupStack::PopAndDestroy( &cmmanager );
   553         }
   553         }
   554 
   554     
   555     const TUid KBrowserUid = { 0x10008D39 };
   555     // launch the browser
   556     TApaTaskList taskList( CEikonEnv::Static()->WsSession() );
   556     iModel->LaunchBrowserL( passedIap );
   557     TApaTask task = taskList.FindApp( KBrowserUid );
       
   558 
       
   559     // Check if the Browser application is already running.        
       
   560     if ( task.Exists() )
       
   561         {
       
   562         HBufC* queryText = StringLoader::LoadLC( 
       
   563                 R_QTN_SNIFFER_QUEST_RESTART_BROWSING_WITH_WLAN );
       
   564 
       
   565         CAknQueryDialog* dlg = CAknQueryDialog::NewL();
       
   566         TInt ret = dlg->ExecuteLD( 
       
   567                 R_RESTART_BROWSING_CONFIRMATION_QUERY,
       
   568                 *queryText );
       
   569 
       
   570         CleanupStack::PopAndDestroy( queryText );
       
   571 
       
   572         if ( ( ret == EAknSoftkeyOk ) || ( ret == EAknSoftkeyYes ) )
       
   573             {
       
   574             // User Press OK or Yes and launch the browser
       
   575             iModel->LaunchBrowserL( passedIap );
       
   576             }
       
   577         else
       
   578             {
       
   579             // clean up the temporary IAP if any
       
   580             iModel->CleanUpCancelledLaunchL();
       
   581 
       
   582             // we are at this point then we can disconnect 
       
   583             // and iModel->DisconnectL() handles view refreshing 
       
   584             iModel->DisconnectL();
       
   585             }
       
   586         }
       
   587     else
       
   588         {
       
   589         // finally launch the browser
       
   590         iModel->LaunchBrowserL( passedIap );
       
   591         }
       
   592     }
   557     }
   593 
   558 
   594 
   559 
   595 // --------------------------------------------------------------------------
   560 // --------------------------------------------------------------------------
   596 // TWsfAiController::ConnectL
   561 // TWsfAiController::ConnectL