Commit 5c89a184 authored by pete谢兆麟's avatar pete谢兆麟

时间选择器选择背景色 抄袭金龙

parent dd31076b
......@@ -323,6 +323,9 @@ extension YHDatePickView: UIPickerViewDelegate,UIPickerViewDataSource {
}
func pickerView(_ pickerView: UIPickerView, titleForRow row: Int, forComponent component: Int) -> String? {
if #available(iOS 14.0, *), pickerView.subviews.count > 1 {
pickerView.subviews[1].backgroundColor = UIColor.brandMainColor6
}
if component == 0 {
return "\((currentDateCom.year!) + row - 99)"
} else if component == 1 {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment