removed xhtml body. fixes #1594

This commit is contained in:
Daniel Gultsch 2016-01-01 16:52:32 +01:00
parent 73e2389eee
commit d875061407

View file

@ -69,15 +69,6 @@ public class MessageGenerator extends AbstractGenerator {
return packet; return packet;
} }
public static void addXhtmlImImage(MessagePacket packet, Message.FileParams params) {
Element html = packet.addChild("html","http://jabber.org/protocol/xhtml-im");
Element body = html.addChild("body","http://www.w3.org/1999/xhtml");
Element img = body.addChild("img");
img.setAttribute("src", params.url.toString());
img.setAttribute("height", params.height);
img.setAttribute("width", params.width);
}
public static void addMessageHints(MessagePacket packet) { public static void addMessageHints(MessagePacket packet) {
packet.addChild("private", "urn:xmpp:carbons:2"); packet.addChild("private", "urn:xmpp:carbons:2");
packet.addChild("no-copy", "urn:xmpp:hints"); packet.addChild("no-copy", "urn:xmpp:hints");
@ -112,9 +103,6 @@ public class MessageGenerator extends AbstractGenerator {
if (message.hasFileOnRemoteHost()) { if (message.hasFileOnRemoteHost()) {
Message.FileParams fileParams = message.getFileParams(); Message.FileParams fileParams = message.getFileParams();
content = fileParams.url.toString(); content = fileParams.url.toString();
if (fileParams.width > 0 && fileParams.height > 0) {
addXhtmlImImage(packet,fileParams);
}
} else { } else {
content = message.getBody(); content = message.getBody();
} }