diff options
Diffstat (limited to 'src/de/gultsch/chat/ui')
-rw-r--r-- | src/de/gultsch/chat/ui/ConversationFragment.java | 17 | ||||
-rw-r--r-- | src/de/gultsch/chat/ui/NewConversationActivity.java | 2 |
2 files changed, 12 insertions, 7 deletions
diff --git a/src/de/gultsch/chat/ui/ConversationFragment.java b/src/de/gultsch/chat/ui/ConversationFragment.java index 81dc1d26..f7513d08 100644 --- a/src/de/gultsch/chat/ui/ConversationFragment.java +++ b/src/de/gultsch/chat/ui/ConversationFragment.java @@ -60,14 +60,14 @@ public class ConversationFragment extends Fragment { activity.xmppConnectionService.sendMessage(conversation.getAccount(),message); chatMsg.setText(""); - if (conversation.getMode()==Conversation.MODE_SINGLE) { + /*if (conversation.getMode()==Conversation.MODE_SINGLE) { conversation.getMessages().add(message); messageList.add(message); - } + }*/ - activity.updateConversationList(); + //activity.updateConversationList(); - messagesView.setSelection(messageList.size() - 1); + //messagesView.setSelection(messageList.size() - 1); } }); @@ -151,9 +151,16 @@ public class ConversationFragment extends Fragment { TextView time = (TextView) view.findViewById(R.id.message_time); if (item.getStatus() == Message.STATUS_UNSEND) { time.setTypeface(null, Typeface.ITALIC); + time.setText("sending\u2026"); } else { - time.setText(UIHelper.readableTimeDifference(item + time.setTypeface(null,Typeface.NORMAL); + if ((item.getConversation().getMode()==Conversation.MODE_SINGLE)||(type != RECIEVED)) { + time.setText(UIHelper.readableTimeDifference(item .getTimeSent())); + } else { + time.setText(item.getCounterpart()+" \u00B7 "+UIHelper.readableTimeDifference(item + .getTimeSent())); + } } return view; } diff --git a/src/de/gultsch/chat/ui/NewConversationActivity.java b/src/de/gultsch/chat/ui/NewConversationActivity.java index d8680841..a41e3e39 100644 --- a/src/de/gultsch/chat/ui/NewConversationActivity.java +++ b/src/de/gultsch/chat/ui/NewConversationActivity.java @@ -252,7 +252,6 @@ public class NewConversationActivity extends XmppActivity { this.accounts = xmppConnectionService.getAccounts(); this.rosterContacts.clear(); for (int i = 0; i < accounts.size(); ++i) { - if (accounts.get(i).getStatus() == Account.STATUS_ONLINE) { xmppConnectionService.getRoster(accounts.get(i), new OnRosterFetchedListener() { @@ -271,7 +270,6 @@ public class NewConversationActivity extends XmppActivity { }); } } - } @Override public boolean onCreateOptionsMenu(Menu menu) { |