앱 초기 실행화면 일명 Splash Screen 에서 상태바 색상이 기본으로 검정색으로 되어 있다.
LunchScreen.xib 파일을 아무리 수정해도 밝은 색(LightContent)이 되지 않는다.
이럴때 프로젝트의 plist 파일에 옵션을 추가 해주면 된다.
Status bar style ->> UIStatusBarStyleLightContent
Status bar is initially hidden ->> NO
View controller-based status bar appearance ->> NO
.plist 내용
입력후 화면
참고로 ImagePicker를 이용하는 경우에 다시 원래대로 상태바가 어두운 색으로 변경이 된다.
이럴때에는 ImagePicker를 상속 받은 CustomImagePicker에서 처리하거나
ImagePicker.delegate에서 처리해주면 된다.
Swift
func navigationController(navigationController: UINavigationController, willShowViewController viewController: UIViewController, animated: Bool) {
UIApplication.sharedApplication().statusBarStyle = .LightContent
}
Objective-C
-(void)navigationController:(UINavigationController *)navigationController willShowViewController:(UIViewController *)viewController animated:(BOOL)animated
{
[[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleLightContent];
}
'iOS > 참고' 카테고리의 다른 글
[iOS8] UITableView 에서 select cell color 적용하기 (0) | 2015.04.29 |
---|---|
UIImageView에 tintColor 적용하기 (0) | 2015.04.28 |
앱 초기 실행화면(Splash Screen)에서 상태바 색상(Statusbar style) 지정 (1) | 2015.04.17 |
[발번] iOS Keychain Services Tasks (0) | 2015.03.17 |
cocoapods 사용법 (0) | 2015.03.13 |
UIImagePickerController 에서 메뉴가 영문으로 나올때 처리 (0) | 2015.02.26 |
댓글을 달아 주세요
짱