2

I'm looking for some hints on how to put UIView on top of the status bar for specific view controller only, not the whole application. I've read some answers on SO but can't seem to fit what I'm looking for.

A good example of this implementation is in the new Facebook Paper app. (view GIF image)

Any helps is appreaciated!

Gaddafi Rusli
  • 320
  • 4
  • 19
  • i never try this my own, but maybe you can get some ideas from this post: http://stackoverflow.com/questions/2666792/add-uiview-above-all-other-views-including-statusbar – Xu Yin Feb 10 '14 at 04:03
  • I tried that before. But the solution doesn't seem to work for UIView, as the windowLevel available to UIWindow, not UIView. I prefer solution that works with UIView created in storyboard. – Gaddafi Rusli Feb 10 '14 at 09:16
  • The Facebook Paper app most likely doesn't place a UIView in top of the status bar. It most likely hides the status bar for whichever views it needs to do so (in iOS 7 anyway). – Nick Feb 12 '14 at 19:54
  • @Nick , if you look at the GIF i provided in the question, it doenst seems like it. At first i thought it's a screenshot of the previous view, but the the content of the status bar seems to be moving, as you see from the GIF. – Gaddafi Rusli Feb 13 '14 at 08:42
  • Ah, sorry, I was replying on my mobile device and did not look at the GIF properly. At a guess, I would say that a snapshot of the status bar is being taken, which is then placed as an image (along with the hiding of the status bar) when the views above are animated down. – Nick Feb 13 '14 at 09:12
  • Actually, I was completely wrong, check this link: http://initwithfunk.com/blog/2014/02/07/how-to-build-the-facebook-paper-status-bar-hover/ – Nick Feb 13 '14 at 09:24
  • @Nick that's perfect! I wonder how u manage to find that post. Thanks! If you post this as an answer, I'll gladly accept it. – Gaddafi Rusli Feb 13 '14 at 12:49

1 Answers1

7

Actually, I was completely wrong, check this link: http://initwithfunk.com/blog/2014/02/07/how-to-build-the-facebook-paper-status-bar-hover/

Nick
  • 939
  • 1
  • 12
  • 19