iOS 8: UITableViewCell detail text not correctly updating

后端 未结 8 759
有刺的猬
有刺的猬 2020-12-30 02:32

tl;dr: Can I cause the detailTextLabel to have its size updated by the auto layout system in iOS on a value change?

Has anyone else had issues with the detailText l

8条回答
  •  滥情空心
    2020-12-30 03:00

    I had a similar problem with a static UITableView. I change a label's text and it doesn't get updated on the screen unless I clicked on the cell or did anything to force update its views. My workaround was to call after updating the text:

    tableView.reloadData()

    P.S This doesn't make any sense; because this is a static table view, and I don't know why it worked, but it did!

提交回复
热议问题