0

各位下午好!

没有人可以帮助我 - 我在 pod 'Koloda'、'4.6' 版本上遇到了这个问题,我不知道该怎么办。

委托未调用 didSwipeCardAtIndex。以前,在 swift 2 上一切正常。现在 Swift 3 & 4 Sample 也没有调用 func ...... https://github.com/Yalantis/Koloda

func koloda(koloda: KolodaView, didSwipedCardAtIndex index: UInt, inDirection direction: SwipeResultDirection) {
    //
}

谢谢大家

4

1 回答 1

0

您可以在 swift 4 中使用此功能

func koloda(koloda: KolodaView, shouldSwipeCardAtIndex index: UInt, inDirection direction: SwipeResultDirection) -> Bool {

        if direction == SwipeResultDirection.left || direction == SwipeResultDirection.right {
            return true
        }

        return false
    }
于 2020-01-20T12:21:04.633 回答