[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:05:37 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-common-internals.git;a=commitdiff;h=7157d9e
The following commit has been merged in the master branch:
commit 7157d9e94744ad6f4aabffd28958cd7c0b408df5
Author: Dan Vrátil <dvratil at redhat.com>
Date: Fri Oct 12 13:34:20 2012 +0200
Return empty clientTypes list when contact is offline
This is a temporary workaround for upstream bug [0] that
should be removed when they fix it.
[0] https://bugs.freedesktop.org/show_bug.cgi?id=55883
REVIEW: 106881
BUG: 308217
---
KTp/Models/contact-model-item.cpp | 13 ++++++++++++-
KTp/Models/contact-model-item.h | 1 +
2 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/KTp/Models/contact-model-item.cpp b/KTp/Models/contact-model-item.cpp
index 1bf32d7..1102998 100644
--- a/KTp/Models/contact-model-item.cpp
+++ b/KTp/Models/contact-model-item.cpp
@@ -151,7 +151,7 @@ QVariant ContactModelItem::data(int role) const
case AccountsModel::SSHContactCapabilityRole:
return sshContactCapability();
case AccountsModel::ClientTypesRole:
- return mPriv->mContact->clientTypes();
+ return clientTypes();
default:
break;
}
@@ -252,4 +252,15 @@ bool ContactModelItem::sshContactCapability() const
return contactCanHandleSSHContact && selfCanHandleSSHContact;
}
+QStringList ContactModelItem::clientTypes() const
+{
+ /* Temporary workaround for upstream bug https://bugs.freedesktop.org/show_bug.cgi?id=55883)
+ * Close https://bugs.kde.org/show_bug.cgi?id=308217 when fixed upstream */
+ if (mPriv->mContact->presence().type() == Tp::ConnectionPresenceTypeOffline) {
+ return QStringList();
+ }
+
+ return mPriv->mContact->clientTypes();
+}
+
#include "contact-model-item.moc"
diff --git a/KTp/Models/contact-model-item.h b/KTp/Models/contact-model-item.h
index e581705..b8447a5 100644
--- a/KTp/Models/contact-model-item.h
+++ b/KTp/Models/contact-model-item.h
@@ -54,6 +54,7 @@ private:
bool fileTransferCapability() const;
bool desktopSharingCapability() const;
bool sshContactCapability() const;
+ QStringList clientTypes() const;
struct Private;
friend struct Private;
--
ktp-common-internals packaging
More information about the pkg-kde-commits
mailing list