Giter VIP home page Giter VIP logo

isvimagescrollview's People

Contributors

yuriiik avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

isvimagescrollview's Issues

Not a real issue; just saying thanks!

This is not a real issue so feel free to delete it.

I just wanted to say thanks.
I was having a really frustrating day trying to get this pinch/zoom/pan in a scrollview thing to work using constraints. I had it mostly working but there was always something weird with the content size or position, especially after rotating the screen. All the "tutorials" on how to do it were overly simplistic and didn't actually work very well.

I decided to try your code out and it worked perfectly. I adapted to work with any kind of UIView (as long as you pass an explicit aspect ratio) and it has worked great. Really saved my sanity!

Anyway, I tried looking you up on Twitter and I just saw that you're from Kiev. I hope you and your family are safe and are doing as well as you can, given the circumstances.

Take care dude and thanks again

Occasional Crash on 'scaleImageForScrollViewTransitionFromBounds:'

I get the occasional crash:

[ISVImageScrollView scaleImageForScrollViewTransitionFromBounds:toBounds:]
*** Terminating app due to uncaught exception 'CALayerInvalidGeometry', reason: 'CALayer position contains NaN: [nan nan]'

I think the line 101:

CGSize containedImageSizeOld = [self rectSizeForAspectRatio:self.imageAspectRatio
thatFitsSize:oldSize];

might be returning a zero size and further down the line, it becomes the denominator in a division.

I'm not sure if the fix should be done in 'rectSizeForAspectRatio:thatFitsSize:' or in 'scaleImageForScrollViewTransitionFromBounds'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.