From 7b3cb0c3dd3865f6c01b3b1ea6935a4cd2dd08b9 Mon Sep 17 00:00:00 2001 From: John Preston Date: Wed, 5 Jan 2022 15:09:21 +0300 Subject: [PATCH] Allow non-colored and .tgs Lottie::Icon-s. --- Telegram/SourceFiles/boxes/sessions_box.cpp | 2 -- Telegram/SourceFiles/ui/controls/call_mute_button.cpp | 4 ++-- Telegram/lib_lottie | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/Telegram/SourceFiles/boxes/sessions_box.cpp b/Telegram/SourceFiles/boxes/sessions_box.cpp index ca0e9e3cc..1384a7eb6 100644 --- a/Telegram/SourceFiles/boxes/sessions_box.cpp +++ b/Telegram/SourceFiles/boxes/sessions_box.cpp @@ -289,10 +289,8 @@ void RenameBox(not_null box) { Unexpected("Type in LottieForType."); }(); const auto size = st::sessionBigLottieSize; - static const auto kWhite = style::owned_color(Qt::white); return std::make_unique(Lottie::IconDescriptor{ .path = u":/icons/settings/devices/"_q + path + u".lottie"_q, - .color = kWhite.color(), .sizeOverride = QSize(size, size), .frame = 1, }); diff --git a/Telegram/SourceFiles/ui/controls/call_mute_button.cpp b/Telegram/SourceFiles/ui/controls/call_mute_button.cpp index 523e22a04..d47b7d684 100644 --- a/Telegram/SourceFiles/ui/controls/call_mute_button.cpp +++ b/Telegram/SourceFiles/ui/controls/call_mute_button.cpp @@ -591,13 +591,13 @@ void CallMuteButton::refreshLabels() { void CallMuteButton::refreshIcons() { _icons[0].emplace(Lottie::IconDescriptor{ .path = u":/icons/calls/voice.lottie"_q, - .color = st::groupCallIconFg, + .color = &st::groupCallIconFg, .sizeOverride = _st->lottieSize, .frame = (_iconState.index ? 0 : _iconState.frameTo), }); _icons[1].emplace(Lottie::IconDescriptor{ .path = u":/icons/calls/hands.lottie"_q, - .color = st::groupCallIconFg, + .color = &st::groupCallIconFg, .sizeOverride = _st->lottieSize, .frame = (_iconState.index ? _iconState.frameTo : 0), }); diff --git a/Telegram/lib_lottie b/Telegram/lib_lottie index e1b707d12..5b576ba9b 160000 --- a/Telegram/lib_lottie +++ b/Telegram/lib_lottie @@ -1 +1 @@ -Subproject commit e1b707d128df046894753b99da44ac462ad52b96 +Subproject commit 5b576ba9b90f621b3dd965d44caf8bd71c00f6ae