aboutsummaryrefslogtreecommitdiff
path: root/src/base/QXmppPresence.h
diff options
context:
space:
mode:
authorJeremy Lainé <jeremy.laine@m4x.org>2012-07-21 15:04:49 +0200
committerJeremy Lainé <jeremy.laine@m4x.org>2012-07-21 15:04:49 +0200
commitc69757fe8d23001e5154febc29ec1bc05ad3cd59 (patch)
tree1b52df55f433c7eeac29c42a76ef0db8b8aae632 /src/base/QXmppPresence.h
parentd6694d3db35a553c8930bba083fcc3f5ed4ff124 (diff)
downloadqxmpp-c69757fe8d23001e5154febc29ec1bc05ad3cd59.tar.gz
add QXmppPresence::availableStatusType()
Diffstat (limited to 'src/base/QXmppPresence.h')
-rw-r--r--src/base/QXmppPresence.h16
1 files changed, 15 insertions, 1 deletions
diff --git a/src/base/QXmppPresence.h b/src/base/QXmppPresence.h
index e327a75b..be80ceb0 100644
--- a/src/base/QXmppPresence.h
+++ b/src/base/QXmppPresence.h
@@ -47,6 +47,17 @@ public:
Probe ///< A request for an entity's current presence; SHOULD be generated only by a server on behalf of a user.
};
+ /// This enum is used to describe an availability status.
+ enum AvailableStatusType
+ {
+ Online = 0, ///< The entity or resource is online.
+ Away, ///< The entity or resource is temporarily away.
+ XA, ///< The entity or resource is away for an extended period.
+ DND, ///< The entity or resource is busy ("Do Not Disturb").
+ Chat, ///< The entity or resource is actively interested in chatting.
+ Invisible ///< obsolete XEP-0018: Invisible Presence
+ };
+
/// This enum is used to describe vCard updates as defined by
/// XEP-0153: vCard-Based Avatars
enum VCardUpdateType
@@ -109,6 +120,9 @@ public:
const QXmppPresence::Status& status = QXmppPresence::Status());
~QXmppPresence();
+ AvailableStatusType availableStatusType() const;
+ void setAvailableStatusType(AvailableStatusType type);
+
int priority() const;
void setPriority(int priority);
@@ -157,10 +171,10 @@ private:
QString getTypeStr() const;
void setTypeFromStr(const QString&);
+ 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)