mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-23 06:35:51 +00:00
Various fixes
This commit is contained in:
@@ -724,11 +724,15 @@ public extension CombinedComponent {
|
||||
updatedChild.view.center = updatedChild._position ?? CGPoint()
|
||||
updatedChild.view.transform = CGAffineTransform(scaleX: scale, y: scale)
|
||||
} else {
|
||||
updatedChild.view.bounds = CGRect(origin: CGPoint(), size: updatedChild.size)
|
||||
if updatedChild.view.layer.anchorPoint != CGPoint(x: 0.5, y: 0.5) {
|
||||
updatedChild.view.layer.position = updatedChild._position ?? CGPoint()
|
||||
if updatedChild.view is UIScrollView {
|
||||
updatedChild.view.frame = updatedChild.size.centered(around: updatedChild._position ?? CGPoint())
|
||||
} else {
|
||||
updatedChild.view.center = updatedChild._position ?? CGPoint()
|
||||
updatedChild.view.bounds = CGRect(origin: CGPoint(), size: updatedChild.size)
|
||||
if updatedChild.view.layer.anchorPoint != CGPoint(x: 0.5, y: 0.5) {
|
||||
updatedChild.view.layer.position = updatedChild._position ?? CGPoint()
|
||||
} else {
|
||||
updatedChild.view.center = updatedChild._position ?? CGPoint()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user