[英]How to detect if a UITextField was cleared using the UITextFieldViewModeWhileEditing
there is a UITextField
which has a clear button implemented as follows: 有一个
UITextField
,它具有一个清除按钮,实现如下:
myUITextField.clearButtonMode = UITextFieldViewModeWhileEditing
How do I detect if the UITextField
was cleared using the clear button? 如何检测是否使用清除按钮清除了
UITextField
?
As far as I know you can only detect if UITextField is empty. 据我所知,您只能检测UITextField是否为空。 Is there specific reason you want to detect this specific clear button?
您是否有特定原因要检测此特定的清除按钮?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.