Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

removeFooter之后,scrollViewInsets没有重置 #22

Open
leidi0129 opened this issue May 31, 2018 · 1 comment
Open

removeFooter之后,scrollViewInsets没有重置 #22

leidi0129 opened this issue May 31, 2018 · 1 comment

Comments

@leidi0129
Copy link

你好
我正在使用你的框架搭建也页面的刷新加载功能。出现了以下问题

当我反复调用添加footer,会出现整个scrollView的inset.bottom持续增加。即使我在重新添加之前移除了上一个footer,scrollView的inset.bottom也不会重置。

声明:我没有在调戏框架,而是某个需求页面导致当前页面根据不同的筛选条件,产生分页或者不分页的情况,所以会出现反复调用添加和删除【好像没有找到使header、footer失效的选项_(:з」∠)_ 】

@leidi0129
Copy link
Author

当我将removeFooter改成footer.isHidden来处理时,会出现底部高度高出一个footer

在类CRRefreshFooterView中,isHidden的didSet中scrollView?.contentInset.bottom = scrollViewInsets.bottom + animator.execute

scrollViewInsets.bottom已经是一个footer的高度了,执行动画animator.execute高度也是一个footer高度
所以会出现两个footer的高度。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant