UISlider being clipped by UIImageView in iOS 5 but ok in iOS 7

I have a UISlider control placed right under a play button image. The image is removed once the user taps on the play button. In the initial state, which is that the user has just landed on the screen and not played the video yet, the slider is being rendered as tucked under the image in iOS 5 while it renders over the image (correct) in iOS 7. If the user plays the video and then pauses it, I redisplay the image over the movie player. In this scenario in iOS 5 the slider correctly renders over the image.

Any ideas as to why it does this the first time the screen is rendered ?

Answers


It turns out that in iOS 5, the position of the controls in the designer (both Storyboard and XIB) is important. The slider was positioned above the image (in the left-hand side list of controls). Once I moved it below, it rendered properly in iOS 5. However, iOS 7 doesn't seem to mind the position either way.

Obviously in the pause and then play scenario, the image's order was changing due to being removed and then added again to the view.


Need Your Help

Android: Bottom Layout not Showing in Gallery

android layout gallery

I'm trying to surround the top and bottom of my ImageView in a Gallery with a layout containing a tiled background. The top part seems to be working, but the bottom layout doesn't show. Any ideas w...