我在找這樣的一個類似的實現:https://github.com/umano/AndroidSlidingUpPanel 但是對於iOS。目前我有一個帶有UITableView的ViewController。我重寫此方法,這樣我就可以擴大自來水名單:iOS滑動UITableView
func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) {
print("selected: \(indexPath.row)")
self.view.layoutIfNeeded()
UIView.animateWithDuration(1, animations: {
self.mTableViewTopConstant.constant = 200
self.view.layoutIfNeeded()
})
}
我現在想是這樣的:如果列表擴大,滾動位置是在頂部,當我移動了我的手指(快速掃)列表中,列表應該摺疊。另外,如果可能的話,當我移動手指時,該列表應該遵循我的指示。我深入研究了UIScrollViewDelegate,但是我沒有找到在滾動列表時觸發的方法。有沒有?
這是你的意思嗎?或者我理解你錯了嗎? –
謝謝,會檢查出來。 –