parent
91ba7459cb
commit
75220e571c
|
@ -5,7 +5,11 @@ public class AnimatableImageView: UIImageView {
|
||||||
/// An `Animator` instance that holds the frames of a specific image in memory.
|
/// An `Animator` instance that holds the frames of a specific image in memory.
|
||||||
var animator: Animator?
|
var animator: Animator?
|
||||||
/// A display link that keeps calling the `updateFrame` method on every screen refresh.
|
/// A display link that keeps calling the `updateFrame` method on every screen refresh.
|
||||||
lazy var displayLink: CADisplayLink = CADisplayLink(target: self, selector: #selector(updateFrame))
|
lazy var displayLink: CADisplayLink = {
|
||||||
|
let display = CADisplayLink(target: self, selector: #selector(updateFrame))
|
||||||
|
display.paused = true
|
||||||
|
return display
|
||||||
|
}()
|
||||||
|
|
||||||
/// The size of the frame cache.
|
/// The size of the frame cache.
|
||||||
public var framePreloadCount = 50
|
public var framePreloadCount = 50
|
||||||
|
|
Loading…
Reference in New Issue