Why does my gaze move when I change its center?
2 answers
From Apple API for UIView:
The center is specified within the coordinate system of its observation. Setting this property changes the frame property values accordingly.
Changing the border rectangle to automatically redraw the receiver without calling the drawRect: method. If you want the drawRect: method to be called when the border rectangle changes, set the contentMode property to UIViewContentModeRedraw.
Thus, in essence, change center
, frame
or bounds
will be appropriately resized and resized by changing the corresponding two properties.
+3
a source to share