uifw/AvKon/src/AknCheckBoxSettingPage.cpp
branchRCL_3
changeset 56 d48ab3b357f1
parent 55 aecbbf00d063
equal deleted inserted replaced
55:aecbbf00d063 56:d48ab3b357f1
   144     BaseConstructL();
   144     BaseConstructL();
   145     iExtension = new(ELeave) CAknCheckBoxSettingPageExtension;
   145     iExtension = new(ELeave) CAknCheckBoxSettingPageExtension;
   146 
   146 
   147     CreateCheckBoxBitmapsL();
   147     CreateCheckBoxBitmapsL();
   148 
   148 
       
   149     // Only a reference to the CBase object; not owned
       
   150     CAknSetStyleListBox* listBox = ListBoxControl();
       
   151 
       
   152 	//
       
   153 	// SelectItemL make the view item drawn by default, SetDisableRedraw can remove flick
       
   154 	//
       
   155 	TBool bRedrawDisabled = listBox->View()->RedrawDisabled();
       
   156 	listBox->View()->SetDisableRedraw( ETrue );
   149     GenerateInternalArrayAndGiveToListBoxL();
   157     GenerateInternalArrayAndGiveToListBoxL();
       
   158 	listBox->View()->SetDisableRedraw( bRedrawDisabled );
   150 
   159 
   151     // This updates the CBA
   160     // This updates the CBA
   152     CheckAndSetDataValidity();
   161     CheckAndSetDataValidity();
   153     UpdateCbaL();
   162     UpdateCbaL();
   154 
       
   155     // Only a reference to the CBase object; not owned
       
   156     CAknSetStyleListBox* listBox = ListBoxControl();
       
   157 
   163 
   158     listBox->SetListBoxObserver(this);
   164     listBox->SetListBoxObserver(this);
   159 
   165 
   160     // Set the scroller indication to appear when needed
   166     // Set the scroller indication to appear when needed
   161     listBox->CreateScrollBarFrameL(ETrue, ETrue);
   167     listBox->CreateScrollBarFrameL(ETrue, ETrue);
   202                 }
   208                 }
   203             }
   209             }
   204         if (newResourceId)
   210         if (newResourceId)
   205             {
   211             {
   206             bgc->SetCommandL(3,newResourceId);
   212             bgc->SetCommandL(3,newResourceId);
   207             cba->DrawNow();
   213             cba->DrawDeferred();
   208             }
   214             }
   209         }
   215         }
   210 
   216 
   211     // Construct an appropriate control context for the contained editor areas.
   217     // Construct an appropriate control context for the contained editor areas.
   212     // Context produced is owned by CAknSettingPage.
   218     // Context produced is owned by CAknSettingPage.
   360 
   366 
   361     // Respond to softkey events
   367     // Respond to softkey events
   362     switch (aCommandId)
   368     switch (aCommandId)
   363         {
   369         {
   364         case EAknSoftkeySelect:
   370         case EAknSoftkeySelect:
       
   371             {
       
   372             if ( EnableSingleClickHighlight( aCommandId ) )
       
   373                 {
       
   374                 break;                           
       
   375                 } 
       
   376             // no single click mode was enabled, fall through
       
   377             }           
   365         case EAknSoftkeyMark:
   378         case EAknSoftkeyMark:
   366         case EAknSoftkeyUnmark:
   379         case EAknSoftkeyUnmark:
   367             if ( AknLayoutUtils::PenEnabled() )
   380             if ( AknLayoutUtils::PenEnabled() )
   368                 {
   381                 {
   369                 if (ListBoxControl()->View()->ItemIsVisible(ListBoxControl()->View()->CurrentItemIndex()))
   382                 if (ListBoxControl()->View()->ItemIsVisible(ListBoxControl()->View()->CurrentItemIndex()))