From 6e9cccedb504bfa325b0fa30088d69db1ee80dc8 Mon Sep 17 00:00:00 2001 From: Alexander Gavriliuk Date: Fri, 22 Mar 2024 20:50:33 +0100 Subject: triage#112 'No emoji found for' text is not translated to other languages in the 'Choose Emoji' floater --- indra/newview/llfloateremojipicker.cpp | 10 +++++++--- indra/newview/skins/default/xui/en/floater_emoji_picker.xml | 1 + 2 files changed, 8 insertions(+), 3 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/llfloateremojipicker.cpp b/indra/newview/llfloateremojipicker.cpp index d08c27bcfc..1fc5740532 100644 --- a/indra/newview/llfloateremojipicker.cpp +++ b/indra/newview/llfloateremojipicker.cpp @@ -40,6 +40,7 @@ #include "llscrolllistitem.h" #include "llsdserialize.h" #include "lltextbox.h" +#include "lltrans.h" #include "llviewerchat.h" namespace { @@ -388,9 +389,12 @@ void LLFloaterEmojiPicker::initialize() } else { - const std::string prompt("No emoji found for "); - std::string title(prompt + '"' + mFilterPattern.substr(1) + '"'); - mPreview->setData(EMPTY_LIST_IMAGE_INDEX, title, prompt.size() + 1, title.size() - 1); + std::size_t begin, end; + LLStringUtil::format_map_t args; + args["[FILTER]"] = mFilterPattern.substr(1); + std::string title(getString("text_no_emoji_for_filter", args)); + LLEmojiDictionary::searchInShortCode(begin, end, title, mFilterPattern); + mPreview->setData(EMPTY_LIST_IMAGE_INDEX, title, begin, end); showPreview(true); } return; diff --git a/indra/newview/skins/default/xui/en/floater_emoji_picker.xml b/indra/newview/skins/default/xui/en/floater_emoji_picker.xml index d21f8c82bc..e4b8f13df7 100644 --- a/indra/newview/skins/default/xui/en/floater_emoji_picker.xml +++ b/indra/newview/skins/default/xui/en/floater_emoji_picker.xml @@ -15,6 +15,7 @@ width="304"> +