mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-08-18 11:30:04 +00:00
Fix bounds calculation for masked sublayers
This commit is contained in:
parent
b29efe9a18
commit
f5e624b51c
@ -115,7 +115,7 @@
|
||||
child.childView.frame = child.layer.bounds;
|
||||
break;
|
||||
case LOTConstraintTypeAlignToBounds: {
|
||||
CGRect selfBounds = self.frame;
|
||||
CGRect selfBounds = self.bounds;
|
||||
CGRect convertedBounds = [child.childView.layer.superlayer convertRect:selfBounds fromLayer:self];
|
||||
child.childView.layer.frame = convertedBounds;
|
||||
} break;
|
||||
@ -142,6 +142,7 @@
|
||||
newChild.layer = layerObject;
|
||||
[layerObject.superlayer insertSublayer:view.layer above:layerObject];
|
||||
|
||||
[layerObject removeFromSuperlayer];
|
||||
view.layer.mask = layerObject;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user