我使用didDeselectRowAtIndexPath
通过不同的故事板像浏览:Segue公司VS didDeselectRowAtIndexPath
func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath) {
let story = ["News","Video","Twitter","Request Info","More"]
let vc = self.storyboard?.instantiateViewControllerWithIdentifier(story[indexPath.row]) as NewsFeedTableViewController
self.presentViewController(vc, animated: true, completion: nil)
}
然而,Navigation Bar
显示不出来,当我使用此功能。但是,当我使用segue时,出现Navigation Bar
。
现在的问题是:
- 在
tableView
Cells
不能Segue公司超过1分镜 - 需要导航栏在App滚动(这似乎需要
Segue
)
任何通过此解决方案?
我无法将普通的'ViewController'导入它,因为它只能推送作为基本视图控制器的'TableViewController'。斯威夫特说“Swift Dynamic Caste Failed”。任何解决方案? – tika
@ user2078462:不,这是不正确的,你可以推动任何viewcontrollers(如果你的父视图中有一个UINavigationCotroller) –
看起来像加载推送新的ViewController的父级的'super.viewDidLoad()' – tika