Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我可以清除 NSDatePicker 吗?
我不想看到任何一天被选中。
谢谢
简短的回答:不!
但是您可以例如将其子类化并替换 drawInRect 方法...
下面的 NSDatePicker 子类可以显示一个空的日期状态并表示一个 nil 绑定。
https://github.com/ThesaurusSoftware/TFDatePicker
运行 TFDatePickerTest 以查看其行为方式。