mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
removed unused function
This commit is contained in:
parent
23f1ec9ac2
commit
96532be765
|
@ -45,7 +45,7 @@ QString TwitchEmotes::cleanUpEmoteCode(const EmoteName &dirtyEmoteCode)
|
|||
EmotePtr TwitchEmotes::getOrCreateEmote(const EmoteId &id,
|
||||
const EmoteName &name_)
|
||||
{
|
||||
static QMap<QString, QString> replacements{
|
||||
static const QMap<QString, QString> replacements{
|
||||
{"[oO](_|\\.)[oO]", "O_o"}, {"\\>\\;\\(", ">("},
|
||||
{"\\<\\;3", "<3"}, {"\\:-?(o|O)", ":O"},
|
||||
{"\\:-?(p|P)", ":P"}, {"\\:-?[\\\\/]", ":/"},
|
||||
|
@ -95,9 +95,4 @@ Url TwitchEmotes::getEmoteLink(const EmoteId &id, const QString &emoteScale)
|
|||
.replace("{scale}", emoteScale)};
|
||||
}
|
||||
|
||||
AccessGuard<std::unordered_map<EmoteName, EmotePtr>> TwitchEmotes::accessAll()
|
||||
{
|
||||
return this->twitchEmotes_.access();
|
||||
}
|
||||
|
||||
} // namespace chatterino
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
|
||||
#include "common/Aliases.hpp"
|
||||
#include "common/UniqueAccess.hpp"
|
||||
#include "providers/twitch/TwitchEmotes.hpp"
|
||||
|
||||
#define TWITCH_EMOTE_TEMPLATE \
|
||||
"https://static-cdn.jtvnw.net/emoticons/v1/{id}/{scale}"
|
||||
|
@ -36,13 +35,13 @@ public:
|
|||
TwitchEmotes();
|
||||
|
||||
EmotePtr getOrCreateEmote(const EmoteId &id, const EmoteName &name);
|
||||
Url getEmoteLink(const EmoteId &id, const QString &emoteScale);
|
||||
AccessGuard<std::unordered_map<EmoteName, EmotePtr>> accessAll();
|
||||
|
||||
private:
|
||||
UniqueAccess<std::unordered_map<EmoteName, EmotePtr>> twitchEmotes_;
|
||||
Url getEmoteLink(const EmoteId &id, const QString &emoteScale);
|
||||
UniqueAccess<std::unordered_map<EmoteId, std::weak_ptr<Emote>>>
|
||||
twitchEmotesCache_;
|
||||
|
||||
std::mutex mutex_;
|
||||
};
|
||||
|
||||
} // namespace chatterino
|
||||
|
|
Loading…
Reference in a new issue