I'm trying to use auto layout with a {320,116} UIScrollView
, with a content view of {960, 116}. I have made it so that the scroll view expands or collapses in height when the user scrolls up or down, and horizontal scrolling is paged (so, a total of three pages).
The problem is that when the view expands or collapses--I do this by changing top space to Top Layout Guide, the content offset value is reset to CGPointZero
, so whenever the view is on page 2 or 3, its is reset to 1 against the user's will as it expands or collapses.
The leading space of UIScrollView
to superview is equal to 0.