ScrollView start scroll only second time that the

2019-08-28 23:42发布

I've a problem with my view in iOS7 with autolayout.

This is my structure: enter image description here

The UITextView content is dynamic so I fit his contentSize dynamically in the viewDidLoad.

In my viewDidAppear I try to fit the contentSize of the MainScroll and the mother view calculated by the sum of UIScrollView height (the little one), Pager height and UITextView height. I logged this height and it returned the correct size: 1300px but the view doesn't scroll.

If I change tab and return here the scroll start to scroll, I've tried to put every piece of code in the viewDidLoad but it doesn't work.

Can you help me?

Thanks and sorry for bad English.

1条回答
别忘想泡老子
2楼-- · 2019-08-29 00:19

Try selecting it and then selecting "reset to suggested constraints" in the storyboard. :).

查看更多
登录 后发表回答