diff options
| author | Jeremy Lainé <jeremy.laine@m4x.org> | 2012-07-21 20:55:16 +0200 |
|---|---|---|
| committer | Jeremy Lainé <jeremy.laine@m4x.org> | 2012-07-21 20:55:16 +0200 |
| commit | 2d5f940cdceb11aadd979ff3f1f6f0584bcf533b (patch) | |
| tree | 31ec0dc559080dd47076c16ab7236e0d82f072d7 /src/base/QXmppPresence.h | |
| parent | 215fe071fb44c172dd6b121a9cb83081ad0bbb0f (diff) | |
| download | qxmpp-2d5f940cdceb11aadd979ff3f1f6f0584bcf533b.tar.gz | |
make QXmppPresence use implicit memory sharing
Diffstat (limited to 'src/base/QXmppPresence.h')
| -rw-r--r-- | src/base/QXmppPresence.h | 28 |
1 files changed, 6 insertions, 22 deletions
diff --git a/src/base/QXmppPresence.h b/src/base/QXmppPresence.h index 886e5a8e..b0aa7c55 100644 --- a/src/base/QXmppPresence.h +++ b/src/base/QXmppPresence.h @@ -28,6 +28,8 @@ #include "QXmppStanza.h" #include "QXmppMucIq.h" +class QXmppPresencePrivate; + /// \brief The QXmppPresence class represents an XMPP presence stanza. /// /// \ingroup Stanzas @@ -108,15 +110,17 @@ public: int m_priority; }; - Q_DECL_DEPRECATED QXmppPresence(QXmppPresence::Type type, const QXmppPresence::Status& status); QXmppPresence::Status Q_DECL_DEPRECATED &status(); const QXmppPresence::Status Q_DECL_DEPRECATED &status() const; void Q_DECL_DEPRECATED setStatus(const QXmppPresence::Status&); /// \endcond QXmppPresence(QXmppPresence::Type type = QXmppPresence::Available); + QXmppPresence(const QXmppPresence &other); ~QXmppPresence(); + QXmppPresence& operator=(const QXmppPresence &other); + AvailableStatusType availableStatusType() const; void setAvailableStatusType(AvailableStatusType type); @@ -161,27 +165,7 @@ public: QStringList capabilityExt() const; private: - AvailableStatusType m_availableStatusType; - Type m_type; - QXmppPresence::Status m_status; - - /// XEP-0153: vCard-Based Avatars - - /// m_photoHash: the SHA1 hash of the avatar image data itself (not the base64-encoded version) - /// in accordance with RFC 3174 - QByteArray m_photoHash; - VCardUpdateType m_vCardUpdateType; - - // XEP-0115: Entity Capabilities - QString m_capabilityHash; - QString m_capabilityNode; - QByteArray m_capabilityVer; - // Legacy XEP-0115: Entity Capabilities - QStringList m_capabilityExt; - - // XEP-0045: Multi-User Chat - QXmppMucItem m_mucItem; - QList<int> m_mucStatusCodes; + QSharedDataPointer<QXmppPresencePrivate> d; }; #endif // QXMPPPRESENCE_H |
