summaryrefslogtreecommitdiff
path: root/indra/llui/llemojidictionary.h
diff options
context:
space:
mode:
authorAlexander Gavriliuk <alexandrgproductengine@lindenlab.com>2023-04-19 01:39:42 +0200
committerAlexander Gavriliuk <alexandrgproductengine@lindenlab.com>2023-04-20 03:55:02 +0200
commit97b0ba2a6d2596da867043077e32065653d44f6e (patch)
tree896599c3ab441be09998b0e58b40bde6700cfdbd /indra/llui/llemojidictionary.h
parent8dad411e9055c32a753e575ccd6142073eb27aae (diff)
SL-19575 LLFloaterEmojiPicker - Add filter by category
Diffstat (limited to 'indra/llui/llemojidictionary.h')
-rw-r--r--indra/llui/llemojidictionary.h14
1 files changed, 11 insertions, 3 deletions
diff --git a/indra/llui/llemojidictionary.h b/indra/llui/llemojidictionary.h
index adc22ced58..cbb0ac577d 100644
--- a/indra/llui/llemojidictionary.h
+++ b/indra/llui/llemojidictionary.h
@@ -56,20 +56,28 @@ class LLEmojiDictionary : public LLParamSingleton<LLEmojiDictionary>, public LLI
~LLEmojiDictionary() override {};
public:
+ typedef std::map<llwchar, const LLEmojiDescriptor*> emoji2descr_map_t;
+ typedef std::map<std::string, const LLEmojiDescriptor*> code2descr_map_t;
+ typedef std::map<std::string, std::vector<const LLEmojiDescriptor*>> cat2descrs_map_t;
+
static void initClass();
LLWString findMatchingEmojis(const std::string& needle) const;
+ const LLEmojiDescriptor* getDescriptorFromEmoji(llwchar emoji) const;
const LLEmojiDescriptor* getDescriptorFromShortCode(const std::string& short_code) const;
std::string getNameFromEmoji(llwchar ch) const;
- const std::map<llwchar, const LLEmojiDescriptor*>& getEmoji2Descr() const { return mEmoji2Descr; }
+ const emoji2descr_map_t& getEmoji2Descr() const { return mEmoji2Descr; }
+ const code2descr_map_t& getShortCode2Descr() const { return mShortCode2Descr; }
+ const cat2descrs_map_t& getCategory2Descrs() const { return mCategory2Descrs; }
private:
void addEmoji(LLEmojiDescriptor&& descr);
private:
std::list<LLEmojiDescriptor> mEmojis;
- std::map<llwchar, const LLEmojiDescriptor*> mEmoji2Descr;
- std::map<std::string, const LLEmojiDescriptor*> mShortCode2Descr;
+ emoji2descr_map_t mEmoji2Descr;
+ code2descr_map_t mShortCode2Descr;
+ cat2descrs_map_t mCategory2Descrs;
};
// ============================================================================