Git Product home page Git Product logo

Comments (11)

sochalewski avatar sochalewski commented on September 26, 2024 2

Wow, it looks crazy :) I have no idea at this moment, but I'll try resolve this. Nevertheless feel free to post your solution or pull request when you got something 👍

from uiimageviewalignedswift.

sochalewski avatar sochalewski commented on September 26, 2024 1

@LinusGeffarth Just checked it out on iOS 11.1 and it seems to work just fine.
Take a look at the example I provided and compare it to your code.

Demo

from uiimageviewalignedswift.

LinusGeffarth avatar LinusGeffarth commented on September 26, 2024 1

Hm, true. I figured when I set the image at some other point in my code, it does work w/o issues. It's probably about constraint refreshes I'm committing...
Thanks anyway!

from uiimageviewalignedswift.

sochalewski avatar sochalewski commented on September 26, 2024 1

I got it. Just released 0.5.1-beta which resolves the issue, but may implement some new :)

To check it out change one of lines in your Podfile to
pod 'UIImageViewAlignedSwift', '~> 0.5.1-beta'
and then run pod update --repo-update.

from uiimageviewalignedswift.

sochalewski avatar sochalewski commented on September 26, 2024

Looks like a bug. Thank you for your report, I'll investigate this within a few days. Could you please let me know which version do you use?

from uiimageviewalignedswift.

LinusGeffarth avatar LinusGeffarth commented on September 26, 2024

Cool, thanks for taking care of this. I am currently on 0.5.0 and am using CocoaPods

from uiimageviewalignedswift.

LinusGeffarth avatar LinusGeffarth commented on September 26, 2024

I've found the issue. Whenever you present a view controller on the view controller with the image view inside, and then dismiss it, the bug occurs. Check out the zip. Make sure to run it on an iPad, I've only experienced the issue with popovers.

Test.zip

from uiimageviewalignedswift.

LinusGeffarth avatar LinusGeffarth commented on September 26, 2024

Awesome! I have updated to the beta and it works for the test project. However, for mine, it doesn't. I'm still debugging.
My structure:

Nav
    -> PageController
        -> Nav
            -> VC
                -> TabBar
                    -> Nav
                        -> VC
                            -> VC over full screen, w/ image view
                                -> Popover that's to be dismissed

Maybe that helps...


Edit

I only experience it in one VC so it's probably some other issue. Geez. Ha!

from uiimageviewalignedswift.

lkravchuk avatar lkravchuk commented on September 26, 2024

I was able to reproduce the bug on the iOS11+ only and it seems that it's still there even in updated 0.5.1-beta. ImageView was added to storyboard with aspect Fit content mode and left alignment ON
You can replicate this behavior by using the system alerts with 0.5.0
Or by pushing some view with 0.5.1-beta
Trying to figure out how to fix it

Update
Well, still have no idea why, but it seems that on iOS 11 any changes on parent view controller causes the showing of image and realImageView?.image at the same time, so using the last fix from beta branch + re-assigning the image inside didMoveToWindow() fixed it for me, but would be great if to test this more to be sure that there will be no more side-effects.

from uiimageviewalignedswift.

ToniTornado avatar ToniTornado commented on September 26, 2024

I used the latest beta branch but still had this issue. To reproduce it, I had to start the app, dismiss it (home button), bring it to foreground and then rotate the view.

Maybe this helps someone debugging it...

from uiimageviewalignedswift.

Niegazowana avatar Niegazowana commented on September 26, 2024

Hi! I opened a PR to solve this issue

from uiimageviewalignedswift.

Related Issues (20)

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.