diff options
author | BrianBlade <n.gelbertz@gmail.com> | 2015-04-04 08:57:03 +0200 |
---|---|---|
committer | BrianBlade <n.gelbertz@gmail.com> | 2015-04-04 09:05:22 +0200 |
commit | 34a404ca31ef83973223cd93cdc75b6ae8c497de (patch) | |
tree | 0bddca2811e568e33f7f488be9010819fb781210 | |
parent | 32e64c68694f364209a0a268c7e349995aa24371 (diff) |
Dont end selectedConversation on swipe
Call mConversationFragment.reinit() instead.
Add separate undo string for swipe MUC.
-rw-r--r-- | src/main/java/eu/siacs/conversations/ui/ConversationActivity.java | 9 | ||||
-rw-r--r-- | src/main/res/values-de/strings.xml | 3 | ||||
-rw-r--r-- | src/main/res/values/strings.xml | 3 |
3 files changed, 11 insertions, 4 deletions
diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java b/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java index 364e2ce4..d2a5c855 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java +++ b/src/main/java/eu/siacs/conversations/ui/ConversationActivity.java @@ -193,7 +193,8 @@ public class ConversationActivity extends XmppActivity } else if (getSelectedConversation() == item) { setSelectedConversation(listAdapter.getItem(0)); - endConversation(item, false, true); + ConversationActivity.this.mConversationFragment + .reInit(getSelectedConversation()); } return new EnhancedListView.Undoable() { @@ -210,7 +211,11 @@ public class ConversationActivity extends XmppActivity @Override public String getTitle() { - return getResources().getString(R.string.title_undo_swipe_out_conversation); + if (item.getMode() == Conversation.MODE_MULTI) { + return getResources().getString(R.string.title_undo_swipe_out_muc); + } else { + return getResources().getString(R.string.title_undo_swipe_out_conversation, item.getName()); + } } }; } diff --git a/src/main/res/values-de/strings.xml b/src/main/res/values-de/strings.xml index e9ef5c66..59a152bf 100644 --- a/src/main/res/values-de/strings.xml +++ b/src/main/res/values-de/strings.xml @@ -427,7 +427,8 @@ <string name="no_application_found_to_display_location">Keine App für die Standort-Anzeige gefunden</string> <string name="location">Standort</string> <string name="received_location">Standort empfangen</string> - <string name="title_undo_swipe_out_conversation">Unterhaltung beendet</string> + <string name="title_undo_swipe_out_conversation">Unterhaltung mit %s beendet</string> + <string name="title_undo_swipe_out_muc">Konferenz beendet. Du wirst keine weiteren Nachrichten aus diesem Chat empfangen.</string> <plurals name="select_contact"> <item quantity="one">%d Kontakt ausgewählt</item> <item quantity="other">%d Kontakte ausgewählt</item> diff --git a/src/main/res/values/strings.xml b/src/main/res/values/strings.xml index 4cd7415a..e36cac26 100644 --- a/src/main/res/values/strings.xml +++ b/src/main/res/values/strings.xml @@ -455,7 +455,8 @@ <string name="no_application_found_to_display_location">No application found to display location</string> <string name="location">Location</string> <string name="received_location">Received location</string> - <string name="title_undo_swipe_out_conversation">Conversation closed</string> + <string name="title_undo_swipe_out_conversation">Conversation with %s closed</string> + <string name="title_undo_swipe_out_muc">Conference closed. You won\'t receive new messages from this chat.</string> <plurals name="select_contact"> <item quantity="one">Select %d contact</item> <item quantity="other">Select %d contacts</item> |