Move the message add code after the send.

This commit is contained in:
Guillaume BIENKOWSKI 2014-05-22 15:55:12 +02:00
parent 42199f23dc
commit 78e1ae145c

View file

@ -326,8 +326,8 @@ static void message_status(LinphoneChatMessage* msg,LinphoneChatMessageState sta
if(externalUrl) {
linphone_chat_message_set_external_body_url(msg, [[externalUrl absoluteString] UTF8String]);
}
[tableController addChatEntry:linphone_chat_message_ref(msg)];
linphone_chat_room_send_message2(chatRoom, msg, message_status, self);
[tableController addChatEntry:linphone_chat_message_ref(msg)];
[tableController scrollToBottom:true];
return TRUE;
}