Move twitch emote-related stuff to TwitchEmotes class

This commit is contained in:
Rasmus Karlsson
2018-06-05 17:13:29 +02:00
committed by fourtf
parent 3a8ceede4e
commit e12d386a5a
8 changed files with 177 additions and 136 deletions
+3 -3
View File
@@ -88,7 +88,7 @@ void EmotePopup::loadChannel(ChannelPtr _channel)
// fourtf: the entire emote manager needs to be refactored so there's no point in trying to
// fix this pile of garbage
for (const auto &set : app->emotes->twitchAccountEmotes[userID.toStdString()].emoteSets) {
for (const auto &set : app->emotes->twitch.emotes[userID.toStdString()].emoteSets) {
// TITLE
messages::MessageBuilder builder1;
@@ -107,8 +107,8 @@ void EmotePopup::loadChannel(ChannelPtr _channel)
builder2.append((new EmoteElement(value, MessageElement::Flags::AlwaysShow))
->setLink(Link(Link::InsertText, key)));
}(QString::fromStdString(emote.code),
app->emotes->getTwitchEmoteById(QString::fromStdString(emote.id).toLong(),
QString::fromStdString(emote.code)));
app->emotes->twitch.getEmoteById(QString::fromStdString(emote.id).toLong(),
QString::fromStdString(emote.code)));
}
emoteChannel->addMessage(builder2.getMessage());