Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot swipe between images #260

Open
hughbe opened this issue Feb 11, 2018 · 5 comments
Open

Cannot swipe between images #260

hughbe opened this issue Feb 11, 2018 · 5 comments

Comments

@hughbe
Copy link

hughbe commented Feb 11, 2018

If I provide

let dataSource = NYTPhotoViewerArrayDataSource(photos: photos)
let photosViewController = NYTPhotosViewController(dataSource: dataSource, initialPhotoIndex: 0, delegate: nil)

I cannot swipe between photos, as there is only one view controller in the created view controller. I would expect to be able to swipe to change photos if there are more than one

@KwanAtFoursquare
Copy link

same issue, did you make any headway?

@AlexHrom
Copy link

Me too, has any solution?

@odaeagle
Copy link

odaeagle commented Jun 8, 2018

@hughbe @KwanAtFoursquare @AlexHrom

Make sure you have a strong reference to the view controller. it may happen if you only do

let controller = NYTPhotosViewController(...)
self.present(controller ...)

try have an instance variable that

self.presented = controller

@youmee
Copy link

youmee commented Jun 10, 2018

@odaeagle not helped

@algenepulido
Copy link

Try to use strong reference for the Data Source.

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

No branches or pull requests

6 participants