在SWRevealViewController
呼叫revealToggle:
(菜单)中需要:
someButton.addTarget(self.revealViewController(), action: Selector("revealToggle:"), forControlEvents: UIControlEvents.TouchUpInside)
self.view.addGestureRecognizer(self.revealViewController().panGestureRecognizer())
self.view.addGestureRecognizer(self.revealViewController().tapGestureRecognizer())
但这仅在按下按钮 ( TouchUpInside
) 时有效。我怎么能立即调用它?就在viewDidLoad
什么时候view
显示