connectionmonitoring/connectionmonitorui/src/ConnectionMonitorUiContainer.cpp
branchRCL_3
changeset 15 4dc3bb0099b0
parent 4 77415202bfc8
child 19 22c3c67e5001
equal deleted inserted replaced
13:68f0c7cd80ec 15:4dc3bb0099b0
   102                                          /*ELbmDoesNotOwnItemArray*/ );
   102                                          /*ELbmDoesNotOwnItemArray*/ );
   103     iListBox->Model()->SetItemTextArray( iConnectionArray );
   103     iListBox->Model()->SetItemTextArray( iConnectionArray );
   104     iListBox->Model()->SetOwnershipType( ELbmDoesNotOwnItemArray );
   104     iListBox->Model()->SetOwnershipType( ELbmDoesNotOwnItemArray );
   105     
   105     
   106     TInt actCount = iConnectionArray->MdcaCount() - 1;
   106     TInt actCount = iConnectionArray->MdcaCount() - 1;
   107 	
   107     
   108 	if ( actCount > KErrNotFound )
   108     if ( actCount > KErrNotFound )
   109 		{
   109 		{
   110 		iListBox->SetCurrentItemIndex( aSelectedItem > actCount ? actCount : aSelectedItem );	    
   110 		iListBox->SetCurrentItemIndex( aSelectedItem > actCount ? actCount : aSelectedItem );	    
   111 		}
   111 		}
   112 
   112 
   113     SetIconsL();
   113     SetIconsL();
   121 
   121 
   122     GetPanesL();
   122     GetPanesL();
   123     SetRect( aRect );    
   123     SetRect( aRect );    
   124     ActivateL();
   124     ActivateL();
   125 
   125 
   126     isWlanSupported = FeatureManager::FeatureSupported( KFeatureIdProtocolWlan ); 
   126     isWlanSupported = FeatureManager::FeatureSupported( KFeatureIdProtocolWlan );
       
   127     iOldConnectionCount = iConnectionArray->MdcaCount();
   127 
   128 
   128     CMUILOGGER_LEAVEFN( "CConnectionMonitorUiContainer::ConstructL" );
   129     CMUILOGGER_LEAVEFN( "CConnectionMonitorUiContainer::ConstructL" );
   129     }
   130     }
   130 
   131 
   131 // ---------------------------------------------------------
   132 // ---------------------------------------------------------
   270 // ---------------------------------------------------------
   271 // ---------------------------------------------------------
   271 //
   272 //
   272 void CConnectionMonitorUiContainer::OnTimerEventL()
   273 void CConnectionMonitorUiContainer::OnTimerEventL()
   273     {
   274     {
   274     iListBox->DrawNow();
   275     iListBox->DrawNow();
       
   276     //Update the scrollbar only if connection count has changed
       
   277     //
       
   278     TInt iNewConnectionCount = iConnectionArray->MdcaCount();
       
   279     if ( iOldConnectionCount != iNewConnectionCount )
       
   280         {
       
   281         iListBox->UpdateScrollBarsL();
       
   282         }
       
   283     iOldConnectionCount = iNewConnectionCount;
   275     PushAndRefreshNaviPaneL();
   284     PushAndRefreshNaviPaneL();
   276     }
   285     }
   277 
   286 
   278 // ---------------------------------------------------------
   287 // ---------------------------------------------------------
   279 // CConnectionMonitorUiContainer::DrawFirstAllListBoxItem
   288 // CConnectionMonitorUiContainer::DrawFirstAllListBoxItem