5

Can someone please explain why:

UIView.animate(withDuration: 0.333)
{
    self.someView.transform = CGAffineTransform(scaleX: 0.3, y: 0.3).translatedBy(x: 100, y: 100)
}

does not work? The above immediately performs the translation; only the scaling is animated.

Also, why does this dirty trick work?

Thanks!

Community
  • 1
  • 1
meaning-matters
  • 21,929
  • 10
  • 82
  • 142
  • 1
    About the "dirty trick" - You can open a bug at apple's bug reporter... And wait for response that will come about 50 years later – Yitzchak Mar 02 '17 at 21:28

1 Answers1

-1

Could you provide more code details? I was solved similar issue. In my situation the gesture delegate was applied to superview insted of subview. So translateBy applied to superview in gesture delegate does not affect expected subview. I solved it by delegate gesture recognizer for subview directly.

Dmitry
  • 141
  • 1
  • 8