开发者

UISeachBar and keyboard appearing, disappearing, and then appearing again

开发者 https://www.devze.com 2023-03-14 02:24 出处:网络
I have a UISearchBar which can become first responder. In the same screen I have a tableview whose rows the user can touch to go to a new screen. Howeve开发者_如何学Gor, when the search bar is active

I have a UISearchBar which can become first responder. In the same screen I have a tableview whose rows the user can touch to go to a new screen. Howeve开发者_如何学Gor, when the search bar is active and the keyboard is up, if the user touches one of the table rows to go to a new screen and then goes back, the keyboard reappears, disappears, and then appears again one last time. Any ideas what's causing this?


It seems you are popping view controller back after pushing. See if there is this line

[self.navigationController popViewControllerAnimated:YES];

you have in viewWillAppear/viewDidAppear method of the next screen

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号