[Telepathy-commits] [telepathy-qt4/master] Contact: Added qHash function for a contact QSharedPointer.

Andre Moreira Magalhaes (andrunko) andre.magalhaes at collabora.co.uk
Tue Feb 24 08:54:22 PST 2009


---
 TelepathyQt4/Client/contact.h |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/TelepathyQt4/Client/contact.h b/TelepathyQt4/Client/contact.h
index f2abd00..eaae37b 100644
--- a/TelepathyQt4/Client/contact.h
+++ b/TelepathyQt4/Client/contact.h
@@ -28,6 +28,7 @@
 
 #include <QObject>
 #include <QSet>
+#include <QSharedPointer>
 #include <QVariantMap>
 
 #include <TelepathyQt4/Types>
@@ -99,6 +100,11 @@ private:
     Private *mPriv;
 };
 
+inline uint qHash(const QSharedPointer<Contact> &contact)
+{
+    return qHash(contact.data());
+}
+
 } // Telepathy::Client
 } // Telepathy
 
-- 
1.5.6.5




More information about the telepathy-commits mailing list