diff -r 7cbcb2896f0e -r a642906a277a phonebookui/phonebookservices/src/cntservicecontactselectionview.cpp --- a/phonebookui/phonebookservices/src/cntservicecontactselectionview.cpp Tue Jul 06 14:05:47 2010 +0300 +++ b/phonebookui/phonebookservices/src/cntservicecontactselectionview.cpp Wed Aug 18 09:39:00 2010 +0300 @@ -17,15 +17,15 @@ #include "cntservicecontactselectionview.h" +#include #include #include -#include "cntservicehandler.h" #include #include -CntServiceContactSelectionView::CntServiceContactSelectionView(CntServiceHandler *aServiceHandler): +CntServiceContactSelectionView::CntServiceContactSelectionView( CntAbstractServiceProvider& aServiceProvider ): CntBaseSelectionView(), -mServiceHandler(aServiceHandler) +mProvider( aServiceProvider ) { connect(mListView, SIGNAL(activated(const QModelIndex&)), this, SLOT(onListViewActivated(const QModelIndex&))); connect( this, SIGNAL(viewClosed()), this, SLOT(aboutToCloseView()) ); @@ -37,6 +37,7 @@ } +// An item in the selection list has been clicked void CntServiceContactSelectionView::onListViewActivated(const QModelIndex &aIndex) { QContact contact = mListModel->contact(aIndex); @@ -52,8 +53,11 @@ void CntServiceContactSelectionView::aboutToCloseView() { - connect(mServiceHandler, SIGNAL(returnValueDelivered()), qApp, SLOT(quit())); - mServiceHandler->completeEdit(0); + QVariant variant; + variant.setValue(KCntServicesReturnValueContactNotModified); + mProvider.CompleteServiceAndCloseApp(variant); + CntViewParameters args; + mMgr->back( args ); } void CntServiceContactSelectionView::aboutToOpenView(CntAbstractViewManager* aMgr, const CntViewParameters viewParameters)