mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-24 07:05:35 +00:00
Various improvements
This commit is contained in:
@@ -420,11 +420,12 @@ public final class ChatTextInputMediaRecordingButton: TGModernConversationInputM
|
||||
animationName = "anim_micToVideo"
|
||||
}
|
||||
|
||||
let animationTintColor = self.useDarkTheme ? .white : self.theme.chat.inputPanel.inputControlColor
|
||||
let _ = self.animationView.update(
|
||||
transition: .immediate,
|
||||
component: AnyComponent(LottieComponent(
|
||||
content: LottieComponent.AppBundleContent(name: animationName),
|
||||
color: self.useDarkTheme ? .white : self.theme.chat.inputPanel.inputControlColor
|
||||
color: animationTintColor
|
||||
)),
|
||||
environment: {},
|
||||
containerSize: animationFrame.size
|
||||
@@ -437,6 +438,7 @@ public final class ChatTextInputMediaRecordingButton: TGModernConversationInputM
|
||||
view.output = self.animationOutput
|
||||
self.updateShadow()
|
||||
}
|
||||
view.setMonochromaticEffect(tintColor: animationTintColor)
|
||||
view.frame = animationFrame
|
||||
|
||||
if previousMode != mode {
|
||||
|
||||
@@ -65,22 +65,12 @@ final class LockView: UIButton, TGModernConversationInputMicButtonLock {
|
||||
}
|
||||
|
||||
func updateTheme(_ theme: PresentationTheme) {
|
||||
// [
|
||||
// "Rectangle.Заливка 1": theme.chat.inputPanel.panelBackgroundColor,
|
||||
// "Rectangle.Rectangle.Обводка 1": theme.chat.inputPanel.panelControlAccentColor,
|
||||
// "Rectangle 2.Rectangle.Обводка 1": theme.chat.inputPanel.panelControlAccentColor,
|
||||
// "Path.Path.Обводка 1": theme.chat.inputPanel.panelControlAccentColor,
|
||||
// "Path 4.Path 4.Обводка 1": theme.chat.inputPanel.panelControlAccentColor
|
||||
// ].forEach { key, value in
|
||||
// idleView.setValueProvider(ColorValueProvider(value.lottieColorValue), keypath: AnimationKeypath(keypath: "\(key).Color"))
|
||||
// }
|
||||
//
|
||||
for keypath in idleView.allKeypaths(predicate: { $0.keys.last == "Color" }) {
|
||||
idleView.setValueProvider(ColorValueProvider(theme.chat.inputPanel.panelControlAccentColor.lottieColorValue), keypath: AnimationKeypath(keypath: keypath))
|
||||
idleView.setValueProvider(ColorValueProvider(theme.chat.inputPanel.panelControlColor.lottieColorValue), keypath: AnimationKeypath(keypath: keypath))
|
||||
}
|
||||
|
||||
for keypath in lockingView.allKeypaths(predicate: { $0.keys.last == "Color" }) {
|
||||
lockingView.setValueProvider(ColorValueProvider(theme.chat.inputPanel.panelControlAccentColor.lottieColorValue), keypath: AnimationKeypath(keypath: keypath))
|
||||
lockingView.setValueProvider(ColorValueProvider(theme.chat.inputPanel.panelControlColor.lottieColorValue), keypath: AnimationKeypath(keypath: keypath))
|
||||
}
|
||||
//
|
||||
// [
|
||||
|
||||
Reference in New Issue
Block a user