aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java
diff options
context:
space:
mode:
authorsteckbrief <steckbrief@chefmail.de>2015-11-06 20:23:43 +0100
committersteckbrief <steckbrief@chefmail.de>2015-11-06 20:23:43 +0100
commit8838a5094812e0540ccfef3334e49e1a5c1a564b (patch)
tree353f4513b8f38b77fd4219c2d92a46b0f87694ff /src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java
parentb22d863c362bb6492240700c0f69f1a5d926f46b (diff)
FileBackend splitted into several util classes for separate concerns: AvatarUtil, StreamUtil, ImageUtil. Unused imports removed.
Diffstat (limited to 'src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java')
-rw-r--r--src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java b/src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java
index b7f3cc67..b958e57e 100644
--- a/src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java
+++ b/src/main/java/de/thedevstack/conversationsplus/http/HttpDownloadConnection.java
@@ -22,6 +22,7 @@ import de.thedevstack.conversationsplus.R;
import de.thedevstack.conversationsplus.entities.Transferable;
import de.thedevstack.conversationsplus.entities.DownloadableFile;
import de.thedevstack.conversationsplus.entities.Message;
+import de.thedevstack.conversationsplus.persistance.FileBackend;
import de.thedevstack.conversationsplus.services.XmppConnectionService;
import de.thedevstack.conversationsplus.utils.CryptoHelper;
@@ -81,7 +82,7 @@ public class HttpDownloadConnection implements Transferable {
extension = lastPart;
}
message.setRelativeFilePath(message.getUuid()+"."+extension);
- this.file = mXmppConnectionService.getFileBackend().getFile(message, false);
+ this.file = FileBackend.getFile(message, false);
String reference = mUrl.getRef();
if (reference != null && reference.length() == 96) {
this.file.setKey(CryptoHelper.hexToBytes(reference));
@@ -235,7 +236,7 @@ public class HttpDownloadConnection implements Transferable {
private void updateImageBounds() {
message.setType(Message.TYPE_FILE);
- mXmppConnectionService.getFileBackend().updateFileParams(message, mUrl);
+ FileBackend.updateFileParams(message, mUrl);
mXmppConnectionService.updateMessage(message);
}