Various fixes

This commit is contained in:
Ilya Laktyushin
2022-07-20 08:17:54 +02:00
parent 5a62788289
commit a3db20c972
14 changed files with 70 additions and 72 deletions

View File

@@ -44,19 +44,23 @@ private func getCoveringViewSnaphot(window: Window1) -> UIImage? {
context.clear(CGRect(origin: CGPoint(), size: size))
context.scaleBy(x: scale, y: scale)
UIGraphicsPushContext(context)
window.badgeView.alpha = 0.0
window.forEachViewController({ controller in
if let controller = controller as? PasscodeEntryController {
controller.displayNode.alpha = 0.0
}
return true
})
window.hostView.containerView.drawHierarchy(in: CGRect(origin: CGPoint(), size: unscaledSize), afterScreenUpdates: false)
window.hostView.containerView.drawHierarchy(in: CGRect(origin: CGPoint(), size: unscaledSize), afterScreenUpdates: true)
window.forEachViewController({ controller in
if let controller = controller as? PasscodeEntryController {
controller.displayNode.alpha = 1.0
}
return true
})
window.badgeView.alpha = 1.0
UIGraphicsPopContext()
}).flatMap(applyScreenshotEffectToImage)
}