views:

683

answers:

1

I am looking at example provided by Apple called LocateMe. I am basing my application on similar UI flow. In that example the top bar of the screen is black. Looking in the code and xib file I am not able to figure out how did they get that black bar on the top. When I set up my project exactly like them, I get blue bar. Please help.

+4  A: 

That particular project did it by setting UIStatusBarStyle to UIStatusBarStyleOpaqueBlack in their Info.plist (which is why you couldn't find it). You can also achieve this in code this way:

[[NSApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleBlackOpaque];

EDIT: I re-read your question, and it's not clear whether you're asking about the navigation controller bar or the status bar (which is the bar at the very top of the screen). The above is for the status bar. The Navigation Controller bar was set to black by going to the GetLocationSetupView.xib and selecting the Navigation Bar and selecting the "Black Opaque" style.

Rob Napier
I was asking about the status bar. Thanks for the answer. It solved my problem.
Shirish