iOS 设置状态栏的背景颜色

设置状态栏的背景颜色

- (void)setStatusBarBackgroundColor:(UIColor *)color

{

UIView *statusBar = [[[UIApplication sharedApplication] valueForKey:@"statusBarWindow"] valueForKey:@"statusBar"];

if ([statusBar respondsToSelector:@selector(setBackgroundColor:)]) {

statusBar.backgroundColor = color;

}

}

上一篇:windows窗体继承问题


下一篇:LightOj 1245 --- Harmonic Number (II)找规律