subinspathilettu / SJSegmentedViewController

MIT License
334 stars 126 forks source link

Observer register Issue #12

Closed kishanraiyani03 closed 8 years ago

kishanraiyani03 commented 8 years ago

Hello, I have just integrated your library. When I alloc first time, it works proper. Then I change root view controller of window for logout. Then I again login and change root view controller to the SJSegmentedViewController. It says "An instance 0x7fa0e38b5600 of class UICollectionView was deallocated while key value observers were still registered with it."

I have collection view in my class So I have implemeted as per your doc to observer the scrolling extension HomeVC: SJSegmentedViewControllerViewSource {

func viewForSegmentControllerToObserveContentOffsetChange(controller: UIViewController,
                                                          index: Int) -> UIView {
    return self.clcView
}

Let me know the solution because I am in hurry. Thanks.

subinspathilettu commented 8 years ago

@kishanraiyani03 ,

We have pushed a new version (1.1.0) of SJSegmentedScrollView to CocoaPods. Please verify.

kishanraiyani03 commented 8 years ago

It works. Thanks.