diff -r f4a778e096c2 -r 9da50d567e3c phonebookui/Phonebook2/UIControls/src/CPbk2FetchDlg.cpp --- a/phonebookui/Phonebook2/UIControls/src/CPbk2FetchDlg.cpp Wed Sep 01 12:29:52 2010 +0100 +++ b/phonebookui/Phonebook2/UIControls/src/CPbk2FetchDlg.cpp Tue Sep 14 20:54:53 2010 +0300 @@ -30,7 +30,7 @@ #include #include #include -#include +#include #include #include #include @@ -1327,6 +1327,21 @@ // void CPbk2FetchDlg::RestoreSelectionsL() { + // Remove selections in all pages. Selections will be restored later. + // In case of sort order change the selections will be in a new position, + // that's why they need to be removed. + if ( iPages ) + { + const TInt pageCount = iPages->DlgPageCount(); + for ( TInt i = 0; i < pageCount; i++ ) + { + if ( iPages->DlgPageAt(i).Control().ContactsMarked() ) + { + iPages->DlgPageAt(i).Control().ClearMarks(); + } + } + } + if ( iResults ) { for ( TInt i = 0; i < iResults->Count(); ++i )