今天在寫自定義的cell左劃操作要门,但是因為用了第三方MMDrawerController
,cell的左劃手勢沒有反應,只能劃出MMDrawerController
的側邊论颅。
解決方法:
修改MMDrawerController.m
內(nèi)的方法-isPointContainedWithinCenterViewContentRect:
如下:
-(BOOL)isPointContainedWithinCenterViewContentRect:(CGPoint)point{
CGRect centerViewContentRect = CGRectMake(0, 0, 50.0, self.centerContainerView.height);
// 修改前:CGRect centerViewContentRect = self.centerContainerView.frame;
centerViewContentRect = CGRectIntersection(centerViewContentRect,self.childControllerContainerView.bounds);
return (CGRectContainsPoint(centerViewContentRect, point) &&
[self isPointContainedWithinNavigationRect:point] == NO);
}