mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
another try forsenT
This commit is contained in:
parent
712b1c4f12
commit
ba1767ce10
1 changed files with 9 additions and 9 deletions
|
@ -88,6 +88,14 @@ void Emojis::load()
|
|||
|
||||
void Emojis::loadEmojis()
|
||||
{
|
||||
static std::map<std::string, QString> toneNames{
|
||||
{"1F3FB", "tone1"}, //
|
||||
{"1F3FC", "tone2"}, //
|
||||
{"1F3FD", "tone3"}, //
|
||||
{"1F3FE", "tone4"}, //
|
||||
{"1F3FF", "tone5"}, //
|
||||
};
|
||||
|
||||
QFile file(":/emoji.json");
|
||||
file.open(QFile::ReadOnly);
|
||||
QTextStream s1(&file);
|
||||
|
@ -114,17 +122,9 @@ void Emojis::loadEmojis()
|
|||
|
||||
if (unparsedEmoji.HasMember("skin_variations")) {
|
||||
for (const auto &skinVariation : unparsedEmoji["skin_variations"].GetObject()) {
|
||||
const auto &tone = skinVariation.name.GetString();
|
||||
std::string tone = skinVariation.name.GetString();
|
||||
const auto &variation = skinVariation.value;
|
||||
|
||||
static std::map<QString, QString> toneNames{
|
||||
{"1F3FB", "tone1"}, //
|
||||
{"1F3FC", "tone2"}, //
|
||||
{"1F3FD", "tone3"}, //
|
||||
{"1F3FE", "tone4"}, //
|
||||
{"1F3FF", "tone5"}, //
|
||||
};
|
||||
|
||||
auto variationEmojiData = std::make_shared<EmojiData>();
|
||||
|
||||
auto toneNameIt = toneNames.find(tone);
|
||||
|
|
Loading…
Reference in a new issue