diff options
author | steckbrief <steckbrief@chefmail.de> | 2015-10-23 22:20:54 +0200 |
---|---|---|
committer | steckbrief <steckbrief@chefmail.de> | 2015-10-23 22:20:54 +0200 |
commit | 7aed735df28984e76486f23d17d02981b268930e (patch) | |
tree | ff419b6ac84ff52bf58b8a45b3f1dafc7b0673bf /src/main/java/de/thedevstack/conversationsplus/parser | |
parent | 57cfcefd527195b67b3d96cde921f0f598690946 (diff) |
Fixes FS#47: WiFi only setting in unencrypted chats bug fixed, typo in values for the setting fixed, preferences involved in the decision for auto downloading image links moved to global Utility Class
Diffstat (limited to 'src/main/java/de/thedevstack/conversationsplus/parser')
-rw-r--r-- | src/main/java/de/thedevstack/conversationsplus/parser/MessageParser.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main/java/de/thedevstack/conversationsplus/parser/MessageParser.java b/src/main/java/de/thedevstack/conversationsplus/parser/MessageParser.java index 2969a18d..aa04df2b 100644 --- a/src/main/java/de/thedevstack/conversationsplus/parser/MessageParser.java +++ b/src/main/java/de/thedevstack/conversationsplus/parser/MessageParser.java @@ -23,6 +23,7 @@ import de.thedevstack.conversationsplus.xmpp.chatstate.ChatState; import de.thedevstack.conversationsplus.xmpp.jid.Jid; import de.thedevstack.conversationsplus.xmpp.pep.Avatar; import de.thedevstack.conversationsplus.xmpp.stanzas.MessagePacket; +import de.tzur.conversations.Settings; public class MessageParser extends AbstractParser implements OnMessagePacketReceived { @@ -368,7 +369,11 @@ public class MessageParser extends AbstractParser implements mXmppConnectionService.databaseBackend.createMessage(message); } final HttpConnectionManager manager = this.mXmppConnectionService.getHttpConnectionManager(); - if (message.trusted() && message.treatAsDownloadable() != Message.Decision.NEVER && manager.getAutoAcceptFileSize() > 0) { + if (message.trusted() + && message.treatAsDownloadable() != Message.Decision.NEVER + && ConversationsPlusPreferences.autoAcceptFileSize() > 0 + && ConversationsPlusPreferences.autoDownloadFileLink() + && mXmppConnectionService.isDownloadAllowedInConnection()) { manager.createNewDownloadConnection(message); } else if (!message.isRead()) { mXmppConnectionService.getNotificationService().push(message); |