【发布时间】:2015-10-15 15:10:02
【问题描述】:
我有一个带有tintColor 橙色的 UIAlertController,但每次我单击按钮时,它的颜色都会变为蓝色(我猜是本机颜色)。如何解决?
let orange: UIColor = UIColor(red: 232.0/255, green: 121.0/255, blue: 23.0/255, alpha: 1.0)
let alert = UIAlertController(title: "Welcome!", message: "", preferredStyle: UIAlertControllerStyle.Alert)
alert.view.tintColor = orange
alert.addAction(UIAlertAction(title: "Done", style: UIAlertActionStyle.Default, handler: nil))
self.presentViewController(alert, animated: true, completion: nil)
【问题讨论】:
标签: ios swift uialertcontroller