Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
[libcontacts] Allow caching filter match role. Contributes to JB#47217
This is the role whose data matched the filter pattern.
  • Loading branch information
Chris Adams committed Nov 19, 2019
1 parent 7b695fe commit d4197d25a1bc0b1113d33703067e2e8991c1ca53
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/seasidecache.h
@@ -141,10 +141,11 @@ class CONTACTCACHE_EXPORT SeasideCache : public QObject

struct CacheItem
{
CacheItem() : itemData(0), iid(0), statusFlags(0), contactState(ContactAbsent), listeners(0) {}
CacheItem() : itemData(0), iid(0), statusFlags(0), contactState(ContactAbsent), listeners(0), filterMatchRole(-1) {}
CacheItem(const QContact &contact)
: contact(contact), itemData(0), iid(internalId(contact)),
statusFlags(contact.detail<QContactStatusFlags>().flagsValue()), contactState(ContactAbsent), listeners(0) {}
statusFlags(contact.detail<QContactStatusFlags>().flagsValue()), contactState(ContactAbsent), listeners(0),
filterMatchRole(-1) {}

QContactId apiId() const { return SeasideCache::apiId(contact); }

@@ -201,6 +202,7 @@ class CONTACTCACHE_EXPORT SeasideCache : public QObject
ItemListener *listeners;
QString displayLabelGroup;
QString displayLabel;
int filterMatchRole;
};

struct ContactLinkRequest

0 comments on commit d4197d2

Please sign in to comment.