aboutsummaryrefslogtreecommitdiffstats
path: root/src/eu/siacs/conversations/xmpp
diff options
context:
space:
mode:
authoriNPUTmice <daniel@gultsch.de>2014-08-05 01:36:17 +0200
committeriNPUTmice <daniel@gultsch.de>2014-08-05 01:36:17 +0200
commitf8b4d5f338aede361c2562379d816b45f7bed3b8 (patch)
tree82ea92f7e35b94400e618387d8d522daeb62dc70 /src/eu/siacs/conversations/xmpp
parent629ff3afcdba5e6721a1b63cd0d497d97e3bdbed (diff)
publish avatars
Diffstat (limited to 'src/eu/siacs/conversations/xmpp')
-rw-r--r--src/eu/siacs/conversations/xmpp/pep/Avatar.java3
-rw-r--r--src/eu/siacs/conversations/xmpp/stanzas/MessagePacket.java3
2 files changed, 6 insertions, 0 deletions
diff --git a/src/eu/siacs/conversations/xmpp/pep/Avatar.java b/src/eu/siacs/conversations/xmpp/pep/Avatar.java
index 196c876c..b000c055 100644
--- a/src/eu/siacs/conversations/xmpp/pep/Avatar.java
+++ b/src/eu/siacs/conversations/xmpp/pep/Avatar.java
@@ -6,6 +6,9 @@ public class Avatar {
public String type;
public String sha1sum;
public String image;
+ public int height;
+ public int width;
+ public long size;
public byte[] getImageAsBytes() {
return Base64.decode(image, Base64.DEFAULT);
}
diff --git a/src/eu/siacs/conversations/xmpp/stanzas/MessagePacket.java b/src/eu/siacs/conversations/xmpp/stanzas/MessagePacket.java
index 64a9edc3..433b08c9 100644
--- a/src/eu/siacs/conversations/xmpp/stanzas/MessagePacket.java
+++ b/src/eu/siacs/conversations/xmpp/stanzas/MessagePacket.java
@@ -8,6 +8,7 @@ public class MessagePacket extends AbstractStanza {
public static final int TYPE_NORMAL = 2;
public static final int TYPE_GROUPCHAT = 3;
public static final int TYPE_ERROR = 4;
+ public static final int TYPE_HEADLINE = 5;
public MessagePacket() {
super("message");
@@ -59,6 +60,8 @@ public class MessagePacket extends AbstractStanza {
return TYPE_GROUPCHAT;
} else if (type.equals("error")) {
return TYPE_ERROR;
+ } else if (type.equals("headline")) {
+ return TYPE_HEADLINE;
} else {
return TYPE_UNKNOWN;
}