简体   繁体   English

iOS中导航控制器的点击手势(MMDrawerController)

[英]Tap gesture for navigation controller in iOS (MMDrawerController)

I am building an app for that I have used MMDrawerController as my slide navigation controller. 我正在为使用MMDrawerController作为幻灯片导航控制器构建一个应用程序。

I have gone through their documentation but did not find any code specific to gestures as such. 我浏览了他们的文档,但是没有找到任何特定于手势的代码。 Can you help me out over here. 你能帮我一下吗

  1. Your can add UITapGestureRecognizer to navigationBar with UIGestureRecognizerDelegate of gesture in controller. 您可以在控制器中使用UIGestureRecognizerDelegate将UITapGestureRecognizer添加到navigationBar中。 Overrive func gestureRecognizerShouldBegin, then calculator size than can executive tap gesture (ignore left, right bar item) -> Reture true Overrive func poseRecognizerShouldBegin,然后计算器大小超过执行点击手势(忽略左,右栏项目)-> Reture true
  2. Custom title of navigationBar with: navigationItem.titleView = otherView and add action to this view navigationBar的自定义标题,其中:navigationItem.titleView = otherView并向此视图添加操作

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM