AdvanceiOS动画引擎
Advance 是一个纯 Swift 编写的框架,可为开发者提供强大的动画功能。只要一个简单API,就能实现复杂的动画效果。
示例代码:
import Advance
class MyClass {
let center: Animatable<CGPoint>
init() {
...
center.changed.observe { (value) in
// Do something every time the center value changes
}
}
}
let foo = MyClass()
// foo.center.animateTo(...)
// foo.center.springTo(...)
// foo.center.decay(...)
// foo.center.animate(<custom animation type>)
评论
