--- a/phonebookui/phonebookservices/src/cntservicecontactfetchview.cpp Mon Aug 23 16:06:28 2010 +0300
+++ b/phonebookui/phonebookservices/src/cntservicecontactfetchview.cpp Fri Sep 03 14:32:33 2010 +0300
@@ -234,12 +234,6 @@
// Set action filter
mAction = aArgs.value(ESelectedAction).toString();
- // ESelectedAction is defined in cntviewparams.h
-
- // Has never been implemented.
- //QString filterStr = aArgs.value(KCntServiceViewParamFilter).toString();
- // KCntServiceViewParamFilter is defined in cntserviceviewparams.h
-
if (mAction == KCntActionSms)
{
QContactActionFilter actionFilter;
@@ -254,9 +248,15 @@
}
else if (mAction == KCntActionEmail)
{
- QContactActionFilter actionFilter;
- actionFilter.setActionName("email");
- mListModel->setFilter(actionFilter);
+ QContactDetailFilter emailFilter;
+ emailFilter.setMatchFlags( QContactDetailFilter::MatchContains );
+ emailFilter.setDetailDefinitionName(
+ QContactEmailAddress::DefinitionName,
+ QContactEmailAddress::FieldEmailAddress );
+ // we need to give something to filter for the email filter
+ emailFilter.setValue( "@" );
+ mListModel->setFilter( emailFilter );
+
}
else
{