我在 iOS 故事板上有一个原型单元格,其中包括UIProgressView
.
定期执行的后台进程会通知委托人它已启动。该委托应该使UIProgressView
表格单元格上可见,但这没有发生。即使我可以看到被调用的委托,它也不会导致UIProgressView
出现。
委托方法尝试获取指向UIProgressView
这样的指针:
UIProgressView* view = (UIProgressView*) [[[self tableView:myTableView cellForRowAtIndexPath:[NSIndexPath indexPathForRow:i inSection:0]] contentView] viewWithTag:MyProgressViewTag];
whereviewWithTag
设置为UIProgressView
.
我曾尝试调用[myTableView reloadData]
并[myTableView setNeedsDisplay]
尝试强制重绘单元格,但它没有奏效。
有任何想法吗?