天天看点

UIAlertController + UIPickerView完美结合

参照例子:http://www.oschina.net/code/snippet_2450779_53800。。

要将UIPickerView显示在UIAlertController上,需要在title设置的时候加换行符类似

 let alertViewController = UIAlertController(title:"商品类型\n\n\n\n\n\n\n\n\n\n\n", message:nil, preferredStyle: UIAlertControllerStyle.ActionSheet)