JNWCollectionView
JNWCollectionView copied to clipboard
Wrong contentInsets when connected mouse
If i connected mouse, then scrollView has wrong contentInset because of scroller, without mouse is fine.
Have you set content inset on the scroll view, or do you just mean the bounds are off? Unfortunately I don't have a mouse to test with at the moment. You might want to check what the bounds is that is being used to calculate the layout in the -layout
method in JNWCollectionViewFramework.m
.
Bounds of the collectionView are fine, if i connect mouse then scroller is making some magic stuff and there is more space, and if i turn off mouse then it is relayouting and content is okay. I will debug it around weekend
Hi, @m1entus, have you found the solution?
@jwilling Before connecting mouse:
(lldb) po self.collectionView.contentInsets ▿ NSEdgeInsets
- top : 0.0
- left : 0.0 { ... }
- bottom : 0.0 { ... }
- right : 0.0 { ... }
(lldb) po self.collectionView.contentSize ▿ CGSize
- width : 151.0
- height : 440.0
After connecting mouse:
(lldb) po self.collectionView.contentSize ▿ CGSize
- width : 136.0
- height : 440.0
(lldb) po self.collectionView.contentInsets ▿ NSEdgeInsets
- top : 0.0
- left : 0.0 { ... }
- bottom : 0.0 { ... }
- right : 0.0 { ... }
@danielmartinprieto No i haven't found because i didn't invastige to it
@danielmartinprieto http://stackoverflow.com/questions/15249563/force-nsscrollview-to-use-nsscrollerstyleoverlay-independently-from-input-device this solve issue, i added code to scrollView as a temporary solution
Ok found solution, preparing PR...