2.点击键盘上的搜索按钮按下第二个视图控制器
问题:推动一些黑线在第二视图控制器中从右侧移动到左侧..请检查附加的图像以便更好地理解
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
UIViewController *detail = [self.storyboard instantiateViewControllerWithIdentifier:@"SearchDetailViewController"];
[self.navigationController pushViewController:detail animated:YES];
}
答案 0 :(得分:0)
我遇到了同样的问题。你应该先推开搜索栏键盘。
[self.searchBar resignFirstResponder];
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath{
[self.searchBar resignFirstResponder];
UIViewController *detail = [self.storyboard instantiateViewControllerWithIdentifier:@"SearchDetailViewController"];
[self.navigationController pushViewController:detail animated:YES];
}