TapRippleAnimationView
当您点击 UIView 时创建涟漪效果。
安装
只需将以下行添加到您的 Podfile 中
pod 'TapRippleAnimationView'
用法
您可以使用故事板或编程方式轻松使用。
类方式
import TapRippleAnimationView
let effectView = TapRippleAnimationView(frame: rect)
effectView.delegate = self
view.addSubview(effectView)
故事板方式
import TapRippleAnimationView
@IBOutlet weak var tapView: TapRippleAnimationView!
tapView.delegate = self
然后您可以通过 TapRippleAnimationViewDelegate
获取点击动作。
protocol TapRippleAnimationViewDelegate: class {
func tapRippleAnimationViewAction(_ view: TapRippleAnimationView)
}
许可证
TapRippleAnimationView遵循MIT许可协议。请参阅LICENSE文件以获取更多信息。