iOS7 设置navigationBar的颜色,新增了一个属性 barTintColor
CGFloat osVersion = [[UIDevice currentDevice].systemVersion floatValue]; if (osVersion >= 7.0) { rootNa.navigationBar.barTintColor = [UIColor redColor]; } else { rootNa.navigationBar.tintColor = [UIColor redColor]; }