diff options
author | iNPUTmice <daniel@gultsch.de> | 2014-06-11 21:53:25 +0200 |
---|---|---|
committer | iNPUTmice <daniel@gultsch.de> | 2014-06-11 21:53:25 +0200 |
commit | bb9045267393b2a7765d7c121b58c5e7043b525e (patch) | |
tree | a6441672710b78e3041ece15b60481257466b9fa /src/eu/siacs/conversations/ui/ConversationFragment.java | |
parent | 95f1a3d57d6f4a35d4579cf93d24a7621f39cf07 (diff) |
groundwork for offline otr messages
Diffstat (limited to 'src/eu/siacs/conversations/ui/ConversationFragment.java')
-rw-r--r-- | src/eu/siacs/conversations/ui/ConversationFragment.java | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/eu/siacs/conversations/ui/ConversationFragment.java b/src/eu/siacs/conversations/ui/ConversationFragment.java index 8d936781..5d7e9f94 100644 --- a/src/eu/siacs/conversations/ui/ConversationFragment.java +++ b/src/eu/siacs/conversations/ui/ConversationFragment.java @@ -784,7 +784,7 @@ public class ConversationFragment extends Fragment { protected void sendPlainTextMessage(Message message) { ConversationActivity activity = (ConversationActivity) getActivity(); - activity.xmppConnectionService.sendMessage(message, null); + activity.xmppConnectionService.sendMessage(message); messageSent(); } @@ -828,7 +828,7 @@ public class ConversationFragment extends Fragment { conversation .setNextEncryption(Message.ENCRYPTION_NONE); message.setEncryption(Message.ENCRYPTION_NONE); - xmppService.sendMessage(message, null); + xmppService.sendMessage(message); messageSent(); } }); @@ -854,7 +854,7 @@ public class ConversationFragment extends Fragment { conversation .setNextEncryption(Message.ENCRYPTION_NONE); message.setEncryption(Message.ENCRYPTION_NONE); - xmppService.sendMessage(message, null); + xmppService.sendMessage(message); messageSent(); } }); @@ -886,7 +886,7 @@ public class ConversationFragment extends Fragment { ConversationActivity activity = (ConversationActivity) getActivity(); final XmppConnectionService xmppService = activity.xmppConnectionService; if (conversation.hasValidOtrSession()) { - activity.xmppConnectionService.sendMessage(message, null); + activity.xmppConnectionService.sendMessage(message); messageSent(); } else { activity.selectPresence(message.getConversation(), @@ -896,7 +896,8 @@ public class ConversationFragment extends Fragment { public void onPresenceSelected(boolean success, String presence) { if (success) { - xmppService.sendMessage(message, presence); + message.setPresence(presence); + xmppService.sendMessage(message); messageSent(); } } @@ -904,7 +905,7 @@ public class ConversationFragment extends Fragment { @Override public void onSendPlainTextInstead() { message.setEncryption(Message.ENCRYPTION_NONE); - xmppService.sendMessage(message, null); + xmppService.sendMessage(message); messageSent(); } }, "otr"); |