Skip to content

Commit

Permalink
Merge pull request Yalantis#32 from maxcampolo/fix/reload
Browse files Browse the repository at this point in the history
Fix/reload
  • Loading branch information
serejahh authored Dec 9, 2016
2 parents dd65378 + 05fb10b commit cf3f6aa
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Segmentio/Source/Segmentio.swift
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ open class Segmentio: UIView {
}
}
}

open fileprivate(set) var segmentioItems = [SegmentioItem]()
fileprivate var segmentioCollectionView: UICollectionView?
fileprivate var segmentioOptions = SegmentioOptions()
Expand Down Expand Up @@ -323,6 +323,7 @@ open class Segmentio: UIView {
// MARK: Reload segmentio
public func reloadSegmentio() {
segmentioCollectionView?.collectionViewLayout.invalidateLayout()
segmentioCollectionView?.reloadData()
scrollToItemAtContext()
moveShapeLayerAtContext()
}
Expand Down

0 comments on commit cf3f6aa

Please sign in to comment.