~ubuntu-branches/debian/stretch/psi-plus/stretch

« back to all changes in this revision

Viewing changes to src/pubsubsubscription.cpp

  • Committer: Package Import Robot
  • Author(s): Boris Pek
  • Date: 2013-10-23 02:42:20 UTC
  • mfrom: (1.4.7)
  • Revision ID: package-import@ubuntu.com-20131023024220-bk2hyoenqkwfhpgw
Tags: 0.16.242-1
* New upstream release:
  fixed the problem of initialization of private conversation when both
  sides use libotr 4.0.x. (Closes: #724880)
* Update debian/watch: sources were moved.
* Delete psi-plus-content-downloader package and update all related files.
  This plugin is in psi-plus-plugins package now.
* Update debian/control:
  - remove all currently unneeded Replaces and Breaks fields
  - add build dependency on libidn11-dev
* Update debian/rules: simplify get-orig-source section.
* Update debian/copyright:
  - update Source field due to changes in sources location
  - remove copyright holders whose code was deleted from source tree
    (bundled libidn library was removed)

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
18
18
 *
19
19
 */
20
 
 
 
20
 
21
21
#include <QDomDocument>
22
22
#include <QDomElement>
23
23
#include <QString>
25
25
#include "pubsubsubscription.h"
26
26
 
27
27
 
28
 
PubSubSubscription::PubSubSubscription() 
29
 
 
28
PubSubSubscription::PubSubSubscription()
 
29
{
30
30
}
31
31
 
32
 
PubSubSubscription::PubSubSubscription(const QDomElement& e) 
 
32
PubSubSubscription::PubSubSubscription(const QDomElement& e)
33
33
{
34
34
        fromXml(e);
35
35
}
36
36
 
37
 
const QString& PubSubSubscription::jid() const 
38
 
39
 
        return jid_; 
 
37
const QString& PubSubSubscription::jid() const
 
38
{
 
39
        return jid_;
40
40
}
41
41
 
42
 
const QString& PubSubSubscription::node() const 
43
 
 
42
const QString& PubSubSubscription::node() const
 
43
{
44
44
        return node_;
45
45
}
46
46
 
47
 
PubSubSubscription::State PubSubSubscription::state() const 
48
 
49
 
        return state_; 
 
47
PubSubSubscription::State PubSubSubscription::state() const
 
48
{
 
49
        return state_;
50
50
}
51
51
 
52
 
bool PubSubSubscription::isNull() const 
 
52
bool PubSubSubscription::isNull() const
53
53
{
54
54
        return jid_.isEmpty() && node_.isEmpty();
55
55
}
56
56
 
57
 
void PubSubSubscription::fromXml(const QDomElement& e) 
 
57
void PubSubSubscription::fromXml(const QDomElement& e)
58
58
{
59
59
        if (e.tagName() != "subscription")
60
60
                return;
73
73
                state_ = Subscribed;
74
74
}
75
75
 
76
 
QDomElement PubSubSubscription::toXml(QDomDocument& doc) const 
 
76
QDomElement PubSubSubscription::toXml(QDomDocument& doc) const
77
77
{
78
78
        QDomElement s = doc.createElement("subscription");
79
79
        s.setAttribute("node",node_);