Skip to content

Hotfix/fix ios10 bug#154

Open
Calvin-Huang wants to merge 2 commits into
CSStickyHeaderFlowLayout:masterfrom
Calvin-Huang:hotfix/fix_ios10_bug
Open

Hotfix/fix ios10 bug#154
Calvin-Huang wants to merge 2 commits into
CSStickyHeaderFlowLayout:masterfrom
Calvin-Huang:hotfix/fix_ios10_bug

Conversation

@Calvin-Huang

@Calvin-Huang Calvin-Huang commented Oct 24, 2016

Copy link
Copy Markdown

In iOS 10, UICollectionView & UITableView has the mechanism to prefetch cell, thus, there will be some header will not visible in screen and it can not be initialise by calling "layoutAttributesForSupplementaryViewOfKind".

In here, add a check to make sure header is visible to prevent assertion failure.

…ch cell, thus, there will be some header will not visible in screen and it can not be initialise by calling "layoutAttributesForSupplementaryViewOfKind".

In here, add a check to make sure header is visible to prevent assertion failure.

- https://developer.apple.com/videos/play/wwdc2016/219/
@chrene

chrene commented Oct 24, 2016

Copy link
Copy Markdown
Contributor

It still crashes here. Not the first time but the second time it crashed. I'm you are on the right track, but we should investigate the crash a bit more before merging

@ken-jen

ken-jen commented Nov 18, 2016

Copy link
Copy Markdown

Seeing crashes due to the same issue (I think). Disabling prefetching on the UICollectionView seems to avoid the issue for now - but would love to see a fix for this!

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

Successfully merging this pull request may close these issues.

3 participants