From 6c0b977a0e6fc7e9266aed3b0c6afe81396f08b1 Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Mon, 25 Jun 2018 09:25:55 +0200 Subject: [PATCH] use emoji transform for toolbar and muc name --- .../eu/siacs/conversations/ui/ConferenceDetailsActivity.java | 2 +- .../java/eu/siacs/conversations/ui/ConversationsActivity.java | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java b/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java index aa66e9184..8ab6d4c6d 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java +++ b/src/main/java/eu/siacs/conversations/ui/ConferenceDetailsActivity.java @@ -609,7 +609,7 @@ public class ConferenceDetailsActivity extends XmppActivity implements OnConvers String subject = mucOptions.getSubject(); final boolean hasTitle; if (printableValue(roomName)) { - this.binding.mucTitle.setText(roomName); + this.binding.mucTitle.setText(EmojiWrapper.transform(roomName)); this.binding.mucTitle.setVisibility(View.VISIBLE); hasTitle = true; } else if (!printableValue(subject)) { diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationsActivity.java b/src/main/java/eu/siacs/conversations/ui/ConversationsActivity.java index d74a9b627..34a02e1b8 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConversationsActivity.java +++ b/src/main/java/eu/siacs/conversations/ui/ConversationsActivity.java @@ -74,6 +74,7 @@ import eu.siacs.conversations.ui.util.ActivityResult; import eu.siacs.conversations.ui.util.ConversationMenuConfigurator; import eu.siacs.conversations.ui.util.MenuDoubleTabUtil; import eu.siacs.conversations.ui.util.PendingItem; +import eu.siacs.conversations.utils.EmojiWrapper; import eu.siacs.conversations.utils.ExceptionHelper; import eu.siacs.conversations.utils.XmppUri; import eu.siacs.conversations.xmpp.OnUpdateBlocklist; @@ -567,7 +568,7 @@ public class ConversationsActivity extends XmppActivity implements OnConversatio if (mainFragment != null && mainFragment instanceof ConversationFragment) { final Conversation conversation = ((ConversationFragment) mainFragment).getConversation(); if (conversation != null) { - actionBar.setTitle(conversation.getName()); + actionBar.setTitle(EmojiWrapper.transform(conversation.getName())); actionBar.setDisplayHomeAsUpEnabled(true); return; }