mrackwitz / MRProgress

Collection of iOS drop-in components to visualize progress
MIT License
2.55k stars 306 forks source link

Progress overlay background delay/sometimes missing #39

Closed jdmunro closed 10 years ago

jdmunro commented 10 years ago

I have noticed a bug/cosmetic issue with the white background of the progress overlay appearing after a delay, or occasionally not at all. This does not seem to happen in the simulator, but does on an iPhone 4S running 7.1 using the example app.

Using version 0.4.3.

Symptoms:

The background not appearing at all is difficult to reproduce consistently as it does not seem to be deterministic, however, you can see the delay of the background appearing every time by using the sample app (on device) and presenting an overlay view without the animation - observe that the white background appears noticeably after the spinner component.

Video: Unfortunately this isn't quite as clear as I would hoped. The best way to see is to skip through each frame invidually using Quicktime: https://drive.google.com/file/d/0B7hk_IdN2v-QYlQtSG5hdTBYOGFMWWNtZmVpeTR3Tm1kTm5V/edit?usp=sharing

Images: screen shot 2014-05-27 at 11 34 02 screen shot 2014-05-27 at 11 34 07

jdmunro commented 10 years ago

Here's an example of a situation where the background did not actually appear at all, again it is an iPhone 4S running 7.1. In this case, the progress spinner was visible for several seconds before it was dismissed, the background did not appear.

img_0038

mrackwitz commented 10 years ago

Thank you for the very detailed description! I mentioned this one, too, but it is indeed hard to test. The reason for it is that a snapshot is taken for the background. Therefore the whole window hierachy has to be drawn, which may take a while on older devices. After that the blur effect is applied. Because this needs some more time, this is performed concurrent. Because of this the animation will be already started. There is for sure potential for optimization in the custom blur view implementation. But the animation itself could be improved even with a slow blur implementation. Started now to test the animations on an iPhone 4. I can confirm the issue and just found and fixed another one. :wine_glass:

mrackwitz commented 10 years ago

See #40.

jdmunro commented 10 years ago

Thanks for the quick response! I will test that out shortly and see how it goes.

jdmunro commented 10 years ago

I can confirm, those improvements seem to have resolved the problem - will you merge those and release a new pods version?

mrackwitz commented 10 years ago

Yep, will soon release a new pod version. I just want to solve some of the other issues.