[SCM] ktp-common-internals packaging branch, master, updated. debian/15.12.1-2-1839-gf0635e9
Maximiliano Curia
maxy at moszumanska.debian.org
Mon May 9 09:06:57 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-common-internals.git;a=commitdiff;h=8348752
The following commit has been merged in the master branch:
commit 83487525e870a93148b95029fe0008686381fd93
Author: Martin Klapetek <martin.klapetek at gmail.com>
Date: Tue Jul 2 16:31:44 2013 +0200
Return contact row type properly
Reviewed-by: David Edmundson
---
KTp/Models/kpeopletranslationproxy.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/KTp/Models/kpeopletranslationproxy.cpp b/KTp/Models/kpeopletranslationproxy.cpp
index e89f0e8..54f181d 100644
--- a/KTp/Models/kpeopletranslationproxy.cpp
+++ b/KTp/Models/kpeopletranslationproxy.cpp
@@ -66,8 +66,8 @@ QVariant KPeopleTranslationProxy::data(const QModelIndex &proxyIndex, int role)
case Qt::DisplayRole:
return mapToSource(proxyIndex).data(Qt::DisplayRole);
case KTp::RowTypeRole:
- //PersonsModel has only persons and contacts
- if (mapToSource(proxyIndex).parent().isValid()) {
+ //if the person has max 1 child, it's a fake person, so treat it as contact row
+ if (mapToSource(proxyIndex).parent().isValid() || sourceModel()->rowCount(mapToSource(proxyIndex)) <= 1) {
return KTp::ContactRowType;
} else {
return KTp::PersonRowType;
--
ktp-common-internals packaging
More information about the pkg-kde-commits
mailing list