This commit is contained in:
Ali
2020-02-20 18:08:36 +04:00
parent a75bd17b6c
commit f57d6b6168
8323 changed files with 4359 additions and 56254 deletions

View File

@@ -0,0 +1,35 @@
import Foundation
import Display
import TelegramPresentationData
import AsyncDisplayKit
final class LockedWindowCoveringView: WindowCoveringView {
private let contentView: UIImageView
init(theme: PresentationTheme) {
self.contentView = UIImageView()
super.init(frame: CGRect())
self.backgroundColor = theme.chatList.backgroundColor
self.addSubview(self.contentView)
}
required init?(coder aDecoder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
func updateTheme(_ theme: PresentationTheme) {
self.backgroundColor = theme.chatList.backgroundColor
}
func updateSnapshot(_ image: UIImage?) {
if image != nil {
self.contentView.image = image
}
}
override func updateLayout(_ size: CGSize) {
self.contentView.frame = CGRect(origin: CGPoint(), size: size)
}
}