--- a/uifw/AvKon/src/AknPopupSettingPage.cpp Tue Aug 31 15:28:30 2010 +0300
+++ b/uifw/AvKon/src/AknPopupSettingPage.cpp Wed Sep 01 12:16:19 2010 +0100
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2002-2010 Nokia Corporation and/or its subsidiary(-ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of "Eclipse Public License v1.0"
@@ -44,7 +44,7 @@
#include <aknlistboxtfxinternal.h>
#endif //RD_UI_TRANSITION_EFFECTS_LIST
-
+#include <AknPriv.hrh>
// ----------------------------------------------------------------------------
// Extension class definition
@@ -317,7 +317,8 @@
// ensures that correct item gets selected if setting page is
// accepted by clicking the left softkey.
if ( iExtension && iExtension->iFlags.IsSet(
- CAknPopupSettingListExtension::ESingleClickEnabled ) )
+ CAknPopupSettingListExtension::ESingleClickEnabled ) &&
+ ItemExists( iCurrentSelection ) )
{
View()->SetCurrentItemIndex( iCurrentSelection );
}
@@ -676,7 +677,14 @@
SetEditedItemFrameIID( KAknsIIDQsnFrSetOpt, KAknsIIDQsnFrSetOptCenter );
iQueryValue.SetQueryMode( MAknQueryValue::ESettingPageMode );
+ //
+ // SetQueryValue make the view item drawn by default, SetDisableRedraw can remove flick
+ //
+ TBool bRedrawDisabled = PopupSettingListBox()->View()->RedrawDisabled();
+ PopupSettingListBox()->View()->SetDisableRedraw( ETrue );
PopupSettingListBox()->SetQueryValueL( &iQueryValue );
+ PopupSettingListBox()->View()->SetDisableRedraw( bRedrawDisabled);
+
CheckAndSetDataValidity();
UpdateCbaL();
@@ -735,7 +743,6 @@
EXPORT_C void CAknPopupSettingPage::SelectCurrentItemL()
{
-#ifdef RD_TOUCH2
CAknPopupSettingList* list = PopupSettingListBox();
if ( ( list->ItemDrawer()->Flags() &
@@ -744,7 +751,6 @@
{
list->View()->SetCurrentItemIndex( list->CurrentSelection() );
}
-#endif // RD_TOUCH2
PopupSettingListBox()->SelectCurrentItemL();
}
@@ -783,6 +789,14 @@
EXPORT_C void CAknPopupSettingPage::HandlePointerEventL(const TPointerEvent& aPointerEvent)
{
CAknListBoxSettingPage::HandlePointerEventL(aPointerEvent);
+ if ( TPointerEvent::EDrag == aPointerEvent.iType )
+ {
+ if ( !( Rect().Contains( aPointerEvent.iPosition ) ) )
+ {
+ // Clear focus if dragged outside popup
+ PopupSettingListBox()->HandleResourceChange( KAknMessageFocusLost );
+ }
+ }
}
EXPORT_C void* CAknPopupSettingPage::ExtensionInterface( TUid /*aInterface*/ )
@@ -813,4 +827,18 @@
{
}
+//---------------------------------------------------------------------------------------
+// CAknPopupSettingPage::ProcessCommandL()
+// Processes events from the softkeys. (Or translated from key events)
+//---------------------------------------------------------------------------------------
+//
+EXPORT_C void CAknPopupSettingPage::ProcessCommandL( TInt aCommandId )
+ {
+ if ( !EnableSingleClickHighlight( aCommandId ) )
+ {
+ // no single click mode was enabled, just call the base class method
+ CAknSettingPage::ProcessCommandL( aCommandId );
+ }
+ }
+
// End of File