我有一个textfield,我显示了文本字段值字符串的弹出窗口。文本字段没有变得清晰
当我编辑文本字段时清除按钮是可见的,但是,当我单击清除按钮时,文本字段文本不会消失,但弹出窗口被取消。
我该如何解决这个问题?
下面的代码片段
- (void)textFieldDidBeginEditing:(UITextField *)textField
{
if ([popOverController isPopoverVisible])
{
[popOverController dismissPopoverAnimated:YES];
}
if(textField.tag == SERVER_TAG){
if ([[self getServerList] count]) {
[self createPopUp];
}
} else {
[serverNameTf resignFirstResponder];
}
}
- (BOOL)textFieldShouldClear:(UITextField *)textField {
return YES;
}
请把你的代码放在这里...... – Abhishek
编辑我的问题。 –