1
0
mirror of https://github.com/moparisthebest/Yaaic synced 2024-11-04 16:35:05 -05:00

ConversationActivity: onConversationMessage(): Use addBulkMessages()

This commit is contained in:
Sebastian Kaspari 2010-04-12 21:35:10 +02:00
parent 9ddd45ed92
commit 4e683a9717

View File

@ -311,14 +311,8 @@ public class ConversationActivity extends Activity implements ServiceConnection,
Conversation conversation = server.getConversation(target);
MessageListAdapter adapter = conversation.getMessageListAdapter();
while(conversation.hasBufferedMessages()) {
Message message = conversation.pollBufferedMessage();
if (adapter != null) {
adapter.addMessage(message);
} else {
//"MessageListAdapter is null (conversation " + conversation.getName() + " has no adapter assigned)"
}
if (conversation.hasBufferedMessages() && adapter != null) {
adapter.addBulkMessages(conversation.getBuffer());
}
}