Merge branch 'temp-ppp'

# Conflicts:
#	submodules/TelegramUI/Sources/AccountContext.swift
This commit is contained in:
Isaac
2025-03-14 15:37:17 +01:00
11 changed files with 571 additions and 63 deletions

View File

@@ -417,7 +417,20 @@ public final class InlineStickerItemLayer: MultiAnimationRenderTarget {
}
override public var contents: Any? {
didSet {
get {
return super.contents
} set(value) {
#if targetEnvironment(simulator)
if let value, CFGetTypeID(value as CFTypeRef) == CVPixelBufferGetTypeID() {
let pixelBuffer = value as! CVPixelBuffer
super.contents = CVPixelBufferGetIOSurface(pixelBuffer)
} else {
super.contents = value
}
#else
super.contents = value
#endif
if let mirrorLayer = self.mirrorLayer {
mirrorLayer.contents = self.contents
}