diff options
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/llfloateremojipicker.cpp | 24 |
1 files changed, 15 insertions, 9 deletions
diff --git a/indra/newview/llfloateremojipicker.cpp b/indra/newview/llfloateremojipicker.cpp index 1fc5740532..51b31a72ca 100644 --- a/indra/newview/llfloateremojipicker.cpp +++ b/indra/newview/llfloateremojipicker.cpp @@ -489,10 +489,12 @@ void LLFloaterEmojiPicker::fillCategoryRecentlyUsed(std::map<std::string, std::v auto e2d = emoji2descr.find(emoji); if (e2d != emoji2descr.end() && !e2d->second->ShortCodes.empty()) { - const std::string shortcode(e2d->second->ShortCodes.front()); - if (LLEmojiDictionary::searchInShortCode(begin, end, shortcode, mFilterPattern)) + for (const std::string& shortcode : e2d->second->ShortCodes) { - emojis.emplace_back(emoji, shortcode, begin, end); + if (LLEmojiDictionary::searchInShortCode(begin, end, shortcode, mFilterPattern)) + { + emojis.emplace_back(emoji, shortcode, begin, end); + } } } } @@ -521,10 +523,12 @@ void LLFloaterEmojiPicker::fillCategoryFrequentlyUsed(std::map<std::string, std: auto e2d = emoji2descr.find(emoji.first); if (e2d != emoji2descr.end() && !e2d->second->ShortCodes.empty()) { - const std::string shortcode(e2d->second->ShortCodes.front()); - if (LLEmojiDictionary::searchInShortCode(begin, end, shortcode, mFilterPattern)) + for (const std::string& shortcode : e2d->second->ShortCodes) { - emojis.emplace_back(emoji.first, shortcode, begin, end); + if (LLEmojiDictionary::searchInShortCode(begin, end, shortcode, mFilterPattern)) + { + emojis.emplace_back(emoji.first, shortcode, begin, end); + } } } } @@ -557,10 +561,12 @@ void LLFloaterEmojiPicker::fillGroupEmojis(std::map<std::string, std::vector<LLE { if (!descr->ShortCodes.empty()) { - const std::string shortcode(descr->ShortCodes.front()); - if (LLEmojiDictionary::searchInShortCode(begin, end, shortcode, mFilterPattern)) + for (const std::string& shortcode : descr->ShortCodes) { - emojis.emplace_back(descr->Character, shortcode, begin, end); + if (LLEmojiDictionary::searchInShortCode(begin, end, shortcode, mFilterPattern)) + { + emojis.emplace_back(descr->Character, shortcode, begin, end); + } } } } |