-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix CollectionView scroll behaviour when section is empty
Summary: Issue fixed: When a section is empty (0 cells) but has a header/footer supplementary views, calling `scrollToObject:supplementaryKinds:scrollDirection:scrollPosition:animated` wouldn't do anything as the method implementation has an early return if the section doesn't have any cells: ![screen shot 2017-06-15 at 14 07 18](https://user-images.githubusercontent.com/978865/27195239-fd86401e-51d3-11e7-8630-a018fbba6858.png) As the section does have supplementary views and is displayed on screen, there's no reason not to scroll to it. This minor change fixes this detail. Change in internal implementation of one method - all current tests pass. No tests added. - [x] All tests pass. Demo project builds and runs. - [x] I added tests, an experiment, or detailed why my change isn't tested. - [x] I added an entry to the `CHANGELOG.md` for any breaking changes, enhancements, or bug fixes. - [x] I have reviewed the [contributing guide](https://github.com/Instagram/IGListKit/blob/master/.github/CONTRIBUTING.md) Closes #808 Differential Revision: D5353285 Pulled By: rnystrom fbshipit-source-id: 2b6700f98f7d38716d655dfecceb0353d65ef681
- Loading branch information
1 parent
0a292a8
commit e8ddaf8
Showing
3 changed files
with
58 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters