chang to just use a different point
This commit is contained in:
parent
ccf583615e
commit
bcf810d5cb
@ -185,8 +185,7 @@ open class MoleculeListTemplate: ThreeLayerTableViewController, TemplateProtocol
|
|||||||
open override func moleculeLayoutUpdated(_ molecule: MoleculeViewProtocol) {
|
open override func moleculeLayoutUpdated(_ molecule: MoleculeViewProtocol) {
|
||||||
guard let tableView = tableView else { return }
|
guard let tableView = tableView else { return }
|
||||||
|
|
||||||
var point = molecule.convert(molecule.bounds.origin, to: tableView)
|
let point = molecule.convert(molecule.center, to: tableView)
|
||||||
point = CGPoint(x: ceil(point.x), y: ceil(point.y))
|
|
||||||
if let indexPath = tableView.indexPathForRow(at: point), tableView.indexPathsForVisibleRows?.contains(indexPath) ?? false {
|
if let indexPath = tableView.indexPathForRow(at: point), tableView.indexPathsForVisibleRows?.contains(indexPath) ?? false {
|
||||||
performTableViewUpdates()
|
performTableViewUpdates()
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user