Skip to content

Commit

Permalink
fix 2x mode on ipad
Browse files Browse the repository at this point in the history
  • Loading branch information
lkzhao committed Mar 1, 2018
1 parent 76a01ac commit c3c767b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/Extensions/CALayer+Hero.swift
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ internal extension CALayer {
func flatTransformTo(layer: CALayer) -> CATransform3D {
var layer = layer
var trans = layer.transform
while let superlayer = layer.superlayer, superlayer != self {
while let superlayer = layer.superlayer, superlayer != self, !(superlayer.delegate is UIWindow) {
trans = CATransform3DConcat(superlayer.transform, trans)
layer = superlayer
}
Expand Down

0 comments on commit c3c767b

Please sign in to comment.