第 3 方库导入错误 Xcode 没有已知的选择器实例方法

3rd Party Library importing Error Xcode No known instance method for selector

如果这是一个愚蠢的问题,我真的很抱歉。 我想创建一个使用第三方库 infiniteTabController 的应用程序,但是当我编译 example/demo 代码时它工作完美但是当我将它导入我自己的项目时,库文件给出错误 nameNo known instance method for selector 'previousLocationInView:'

代码在这里。

- (void)touchesMoved:(NSSet *)touches withEvent:(UIEvent *)event
  {
 [super touchesMoved:touches withEvent:event];
 if (self.state == UIGestureRecognizerStateFailed) return;
 CGPoint nowPoint = [[touches anyObject] locationInView:self.view];
 CGPoint prevPoint = [[touches anyObject]previousLocationInView:self.view];
  _moveX += prevPoint.x - nowPoint.x;
 _moveY += prevPoint.y - nowPoint.y;
 if (!_drag) {
    if (abs(_moveX) > kM13PanDirectionThreshold) {
        if (_panDirection == M13PanGestureRecognizerDirectionVertical) {
            self.state = UIGestureRecognizerStateFailed;
        }else {
            _drag = YES;
        }
    }else if (abs(_moveY) > kM13PanDirectionThreshold && _moveY > _moveX) {
        if (_panDirection == M13PanGestureRecognizerDirectionHorizontal) {
            self.state = UIGestureRecognizerStateFailed;
        }else {
            _drag = YES;
        }
    }
}

此行提示错误。

CGPoint prevPoint = [[touches anyObject]previousLocationInView:self.view];

第三方库名称为 M13InfiniteTabController

我认为您缺少一些类别 类,演示项目中应该有。

检查演示中是否还有其他 类,如 UIView+Additions.h 或类似的东西。

谢谢