diff options
Diffstat (limited to 'source/QXmppClient.cpp')
| -rw-r--r-- | source/QXmppClient.cpp | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/source/QXmppClient.cpp b/source/QXmppClient.cpp index 400ff7e0..d8b7f182 100644 --- a/source/QXmppClient.cpp +++ b/source/QXmppClient.cpp @@ -67,7 +67,9 @@ /// The default value is 0. QXmppClient::QXmppClient(QObject *parent) - : QObject(parent), m_stream(0), m_clientPresence(QXmppPresence::Available), + : QObject(parent), + m_stream(0), + m_clientPresence(QXmppPresence::Available), m_reconnectionManager(0) { m_stream = new QXmppStream(this); @@ -312,6 +314,14 @@ void QXmppClient::sendMessage(const QString& bareJid, const QString& message) } } +/// Returns the client's current presence. +/// + +QXmppPresence QXmppClient::clientPresence() const +{ + return m_clientPresence; +} + /// Changes the presence of the connected client. /// /// If the presence type is QXmppPresence::Unavailable or the presence status @@ -381,16 +391,6 @@ void QXmppClient::setClientPresence(QXmppPresence::Status::Type statusType) setClientPresence(newPresence); } -/// Function to get the client's current presence. -/// -/// \return Constant reference to the client's presence object -/// - -const QXmppPresence& QXmppClient::getClientPresence() const -{ - return m_clientPresence; -} - /// Function to get reconnection manager. By default there exists a reconnection /// manager. See QXmppReconnectionManager for more details of the reconnection /// mechanism. @@ -615,6 +615,11 @@ void QXmppClient::xmppConnected() // obsolete +const QXmppPresence& QXmppClient::getClientPresence() const +{ + return m_clientPresence; +} + QXmppConfiguration& QXmppClient::getConfiguration() { return m_stream->configuration(); |
