UIView scale without scaling subparagraphs

I am trying to scale a UIView without scaling my subzones, or in my case I just want the subviews to scale on the same axis. I need this hierarchy because I install some gesture recognizers to detect pan and rotation, and I want them to run simultaneously with the parent view.

However, I do not want the scaling to be done at the same time. For some subzones, I want this to happen only vertically or horizontally or not scale at all.

Is there a way to control autoscaling in the UIView moving mode when using CGAffineTransform in UIView?

+7
source share
2 answers

If you guarantee the correct setting of autoresizingMask subviews, you can change the frame frame of the UIView container (it is animated), and subviews will not change the size (if your change mask is correct). Disabling containerView.autoresizesSubviews and changing the frame should also work.

+4
source

Set the autoresizesSubviews to NO , by default it is YES .

0
source

All Articles