2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 06:35:14 +00:00

Search stickers by emoji.

This commit is contained in:
John Preston
2023-01-24 18:46:16 +04:00
parent 65b1a0c9a4
commit c48ac28204
11 changed files with 161 additions and 85 deletions

View File

@@ -70,7 +70,6 @@ constexpr auto kGrayLockOpacity = 0.3;
using Data::StickersSet;
using Data::StickersPack;
using Data::StickersByEmojiMap;
using SetFlag = Data::StickersSetFlag;
[[nodiscard]] std::optional<QColor> ComputeImageColor(const QImage &frame) {
@@ -337,7 +336,7 @@ private:
bool _repaintScheduled = false;
StickersPack _pack;
StickersByEmojiMap _emoji;
base::flat_map<EmojiPtr, StickersPack> _emoji;
bool _loaded = false;
uint64 _setId = 0;
uint64 _setAccessHash = 0;
@@ -729,7 +728,7 @@ void StickerSetBox::Inner::gotSet(const MTPmessages_StickerSet &set) {
p.push_back(doc);
}
_emoji.insert(original, p);
_emoji[original] = std::move(p);
}
});
}