Support intents with mailto:-links, show preview before sending a message.

This commit is contained in:
B. Petersen
2017-03-30 17:55:43 +02:00
parent 30b778c4f6
commit c780ddf081
7 changed files with 111 additions and 82 deletions
@@ -2691,16 +2691,12 @@ public class ChatActivity extends BaseFragment implements NotificationCenter.Not
private void createChat(String urlFinal)
{
int contactId = MrMailbox.createContact("", urlFinal);
int chatId = MrMailbox.createChatByContactId(contactId);
int chatId = MrMailbox.createChatByContactId(MrMailbox.createContact("", urlFinal));
if( chatId != 0 ) {
Bundle args = new Bundle();
args.putInt("chat_id", chatId);
presentFragment(new ChatActivity(args), true /*removeLast*/);
}
else {
Toast.makeText(getParentActivity(), "Cannot create chat.", Toast.LENGTH_LONG).show(); // should not happen
}
}
@Override