#pragma once #include #include #include "common/UniqueAccess.hpp" #include "messages/Emote.hpp" #include "providers/twitch/EmoteValue.hpp" #include "providers/twitch/TwitchAccount.hpp" #include "providers/twitch/TwitchEmotes.hpp" #include "util/ConcurrentMap.hpp" #define TWITCH_EMOTE_TEMPLATE \ "https://static-cdn.jtvnw.net/emoticons/v1/{id}/{scale}" namespace chatterino { class TwitchEmotes { public: TwitchEmotes(); EmotePtr getOrCreateEmote(const EmoteId &id, const EmoteName &name); Url getEmoteLink(const EmoteId &id, const QString &emoteScale); AccessGuard> accessAll(); private: UniqueAccess> twitchEmotes_; UniqueAccess>> twitchEmotesCache_; }; } // namespace chatterino