mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-29 16:58:07 +00:00
Replaced separate click handlers for each spoiler entry with single one.
This commit is contained in:
@@ -46,10 +46,9 @@ void AnimatedSpoilerClickHandler::onClick(ClickContext context) const {
|
||||
} // namespace
|
||||
|
||||
void FillTextWithAnimatedSpoilers(Ui::Text::String &text) {
|
||||
const auto link = std::make_shared<AnimatedSpoilerClickHandler>();
|
||||
for (auto i = 0; i < text.spoilersCount(); i++) {
|
||||
text.setSpoiler(
|
||||
i + 1,
|
||||
std::make_shared<AnimatedSpoilerClickHandler>());
|
||||
text.setSpoiler(i + 1, link);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+1
-1
Submodule Telegram/lib_ui updated: 2f5d5e0e79...1cc74a41c4
Reference in New Issue
Block a user