1
我有这个简单的代码:如何在动画之后执行代码?
-(void) tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
BGEditTextField * theTableViewCell = (BGEditTextField *) [self.tableView cellForRowAtIndexPath:indexPath];
theTableViewCell.displaytextField =true;
[self.tableView scrollToRowAtIndexPath:indexPath atScrollPosition:UITableViewScrollPositionTop animated:YES];
//self.helpFinishUpdating.viewNotToCover = theTableViewCell;
}
一切都只是完美的,我想
self.helpFinishUpdating.viewNotToCover = theTableViewCell
[self.tableView scrollToRowAtIndexPath:indexPath atScrollPosition:UITableViewScrollPositionTop animated:YES];
完成后执行。
我该怎么做到这一点?
我之所以这样做的原因是因为self.helpFinishUpdating.viewNotToCover = theTableViewCell;
对UITableViewCell
的帧位置很敏感。我希望UITableViewCell
在执行之前先到达最终位置。
不够好。但是,那么如果用户启动滚动呢?我可以解决问题,但不是那么简单。 –
没有更好的答案。 –
我认为这是恭维:D – jimpic