2017-12-31 22:58:35 +01:00
|
|
|
#pragma once
|
|
|
|
|
2018-06-26 14:09:39 +02:00
|
|
|
#include "messages/Image.hpp"
|
|
|
|
#include "util/ConcurrentMap.hpp"
|
2017-12-31 22:58:35 +01:00
|
|
|
|
|
|
|
namespace chatterino {
|
|
|
|
|
|
|
|
struct EmoteData {
|
2018-03-31 13:44:15 +02:00
|
|
|
EmoteData() = default;
|
2017-12-31 22:58:35 +01:00
|
|
|
|
2018-06-28 19:38:57 +02:00
|
|
|
EmoteData(Image *_image);
|
2017-12-31 22:58:35 +01:00
|
|
|
|
2018-01-07 02:56:45 +01:00
|
|
|
// Emotes must have a 1x image to be valid
|
2018-06-04 15:11:06 +02:00
|
|
|
bool isValid() const;
|
2018-06-28 19:38:57 +02:00
|
|
|
Image *getImage(float scale) const;
|
2018-01-07 02:56:45 +01:00
|
|
|
|
2018-06-28 19:38:57 +02:00
|
|
|
Image *image1x = nullptr;
|
|
|
|
Image *image2x = nullptr;
|
|
|
|
Image *image3x = nullptr;
|
2018-05-16 03:55:56 +02:00
|
|
|
|
|
|
|
// Link to the emote page i.e. https://www.frankerfacez.com/emoticon/144722-pajaCringe
|
|
|
|
QString pageLink;
|
2017-12-31 22:58:35 +01:00
|
|
|
};
|
|
|
|
|
2018-03-31 13:44:15 +02:00
|
|
|
using EmoteMap = ConcurrentMap<QString, EmoteData>;
|
2018-01-07 02:56:45 +01:00
|
|
|
|
|
|
|
} // namespace chatterino
|