mirror-chatterino2/src/common/Emotemap.hpp

28 lines
610 B
C++

#pragma once
#include "messages/Image.hpp"
#include "util/ConcurrentMap.hpp"
namespace chatterino {
struct EmoteData {
EmoteData() = default;
EmoteData(Image *_image);
// Emotes must have a 1x image to be valid
bool isValid() const;
Image *getImage(float scale) const;
Image *image1x = nullptr;
Image *image2x = nullptr;
Image *image3x = nullptr;
// Link to the emote page i.e. https://www.frankerfacez.com/emoticon/144722-pajaCringe
QString pageLink;
};
using EmoteMap = ConcurrentMap<QString, EmoteData>;
} // namespace chatterino