aboutsummaryrefslogtreecommitdiff
path: root/xmpp-vala/src/module/presence/module.vala
diff options
context:
space:
mode:
authorMarvin W <git@larma.de>2018-01-12 21:03:09 +0100
committerfiaxh <git@mx.ax.lt>2018-01-28 00:38:47 +0100
commit782ae4c049e2b6fab13d7453cbb0e74610e7d200 (patch)
tree1b4cd0a1689cee0c2e2cac2ae9a5fb8ebbe63621 /xmpp-vala/src/module/presence/module.vala
parentd46d071e57e599e8cfb1780597cbecb36881c4d8 (diff)
downloaddino-782ae4c049e2b6fab13d7453cbb0e74610e7d200.tar.gz
dino-782ae4c049e2b6fab13d7453cbb0e74610e7d200.zip
Move Jid class to xmpp-vala, partially refactor namespace
Diffstat (limited to 'xmpp-vala/src/module/presence/module.vala')
-rw-r--r--xmpp-vala/src/module/presence/module.vala18
1 files changed, 8 insertions, 10 deletions
diff --git a/xmpp-vala/src/module/presence/module.vala b/xmpp-vala/src/module/presence/module.vala
index 3488f532..cbc7d365 100644
--- a/xmpp-vala/src/module/presence/module.vala
+++ b/xmpp-vala/src/module/presence/module.vala
@@ -1,5 +1,3 @@
-using Xmpp.Core;
-
namespace Xmpp.Presence {
private const string NS_URI = "jabber:client";
@@ -10,39 +8,39 @@ namespace Xmpp.Presence {
public signal void pre_send_presence_stanza(XmppStream stream, Presence.Stanza presence);
public signal void initial_presence_sent(XmppStream stream, Presence.Stanza presence);
public signal void received_available(XmppStream stream, Presence.Stanza presence);
- public signal void received_available_show(XmppStream stream, string jid, string show);
+ public signal void received_available_show(XmppStream stream, Jid jid, string show);
public signal void received_unavailable(XmppStream stream, Presence.Stanza presence);
- public signal void received_subscription_request(XmppStream stream, string jid);
- public signal void received_unsubscription(XmppStream stream, string jid);
+ public signal void received_subscription_request(XmppStream stream, Jid jid);
+ public signal void received_unsubscription(XmppStream stream, Jid jid);
public bool available_resource = true;
- public void request_subscription(XmppStream stream, string bare_jid) {
+ public void request_subscription(XmppStream stream, Jid bare_jid) {
Presence.Stanza presence = new Presence.Stanza();
presence.to = bare_jid;
presence.type_ = Presence.Stanza.TYPE_SUBSCRIBE;
send_presence(stream, presence);
}
- public void approve_subscription(XmppStream stream, string bare_jid) {
+ public void approve_subscription(XmppStream stream, Jid bare_jid) {
Presence.Stanza presence = new Presence.Stanza();
presence.to = bare_jid;
presence.type_ = Presence.Stanza.TYPE_SUBSCRIBED;
send_presence(stream, presence);
}
- public void deny_subscription(XmppStream stream, string bare_jid) {
+ public void deny_subscription(XmppStream stream, Jid bare_jid) {
cancel_subscription(stream, bare_jid);
}
- public void cancel_subscription(XmppStream stream, string bare_jid) {
+ public void cancel_subscription(XmppStream stream, Jid bare_jid) {
Presence.Stanza presence = new Presence.Stanza();
presence.to = bare_jid;
presence.type_ = Presence.Stanza.TYPE_UNSUBSCRIBED;
send_presence(stream, presence);
}
- public void unsubscribe(XmppStream stream, string bare_jid) {
+ public void unsubscribe(XmppStream stream, Jid bare_jid) {
Presence.Stanza presence = new Presence.Stanza();
presence.to = bare_jid;
presence.type_ = Presence.Stanza.TYPE_UNSUBSCRIBE;