mariohahn / MHVideoPhotoGallery

A Photo and Video Gallery
MIT License
1.96k stars 353 forks source link

Status bar #17

Open bonebox opened 10 years ago

bonebox commented 10 years ago

MHVideoPhotoGallery causes issue with the status bar of the presenting controller. The two main issues I'm having:

  1. It doesn't take into account if the status bar is already hidden. If the status bar is hidden in the presenting controller, MHVideoPhotoGallery makes it appear again (with the side effect of overlapping the navigation bar on the first image).
  2. Because of 1., when MHVideoPhotoGallery is dismissed, the status bar is now visible. The only way to hide it is to first set it to visible, then to hidden again in the dismiss block, but this causes an unwanted visible effect.
  3. If the original status bar color was light, the color gets set to default. Similar to 2, setting it back in the dismiss block causes an unwanted visible effect.

I think if the status bar is already hidden, the MHVideoPhotoGallery should also keep it hidden. Also, it should either a) restore the status bar to the original state before the dismiss block is called, or provide a willDismiss callback that allows the user to set things back before MHVideoPhotoGallery is dismissed to prevent the visible effects.

FloresRobles commented 9 years ago

+1, status bar alpha can be also be hidden in the app if gallery appears -> nav bar is hidden with a tap -> user closes gallery (with swipe gesture)

this forces to use MHStatusBar().alpha = 1.0 ; in return block