From 11e2b1accd933eb9fcb4477a60dd0864d9f72a67 Mon Sep 17 00:00:00 2001 From: steckbrief Date: Mon, 31 Jul 2017 08:44:32 +0200 Subject: Implements FS#245: Implement FiletransferHttp (upload and delete), some minor bug fixes including to fail a JingleTransfer in case criterias are not met --- .../filetransfer/http/delete/DeleteRemoteFileService.java | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'src/main/java/de/thedevstack/conversationsplus/services/filetransfer/http/delete/DeleteRemoteFileService.java') diff --git a/src/main/java/de/thedevstack/conversationsplus/services/filetransfer/http/delete/DeleteRemoteFileService.java b/src/main/java/de/thedevstack/conversationsplus/services/filetransfer/http/delete/DeleteRemoteFileService.java index 2085cf4b..83f7e359 100644 --- a/src/main/java/de/thedevstack/conversationsplus/services/filetransfer/http/delete/DeleteRemoteFileService.java +++ b/src/main/java/de/thedevstack/conversationsplus/services/filetransfer/http/delete/DeleteRemoteFileService.java @@ -1,16 +1,13 @@ package de.thedevstack.conversationsplus.services.filetransfer.http.delete; -import de.thedevstack.conversationsplus.ConversationsPlusApplication; import de.thedevstack.conversationsplus.entities.Account; import de.thedevstack.conversationsplus.entities.Message; import de.thedevstack.conversationsplus.enums.FileStatus; -import de.thedevstack.conversationsplus.persistance.DatabaseBackend; import de.thedevstack.conversationsplus.ui.listeners.SimpleUserDecisionCallback; import de.thedevstack.conversationsplus.utils.MessageUtil; -import de.thedevstack.conversationsplus.utils.UiUpdateHelper; import de.thedevstack.conversationsplus.utils.XmppSendUtil; import de.thedevstack.conversationsplus.xmpp.filetransfer.http.FileTransferHttp; -import de.thedevstack.conversationsplus.xmpp.filetransfer.http.delete.FileTransferHttpDeleteSlotRequestPacketGenerator; +import de.thedevstack.conversationsplus.xmpp.filetransfer.http.delete.FileTransferHttpDeleteRequestPacketGenerator; import de.thedevstack.conversationsplus.xmpp.jid.Jid; import de.thedevstack.conversationsplus.xmpp.stanzas.IqPacket; @@ -36,9 +33,9 @@ public class DeleteRemoteFileService implements SimpleUserDecisionCallback { Account account = this.message.getConversation().getAccount(); Jid host = account.getXmppConnection().findDiscoItemByFeature(FileTransferHttp.NAMESPACE); if (null != host) { - IqPacket request = FileTransferHttpDeleteSlotRequestPacketGenerator.generate(host, path); + IqPacket request = FileTransferHttpDeleteRequestPacketGenerator.generate(host, path); MessageUtil.setAndSaveFileStatus(this.message, FileStatus.DELETING); - XmppSendUtil.sendIqPacket(account, request, new DeleteTokenReceived(remoteFile)); + XmppSendUtil.sendIqPacket(account, request, new DeletedIqPacketReceived(remoteFile)); } } } -- cgit v1.2.3