Latest 0.0.1
Homepage https://github.com/royliu1990/EasyAnimationSwift
License MIT
Platforms ios 8.0, requires ARC
Dependencies RxSwift, RxCocoa, RxOptional
Authors

Encapsulation of CAAnimation in swift, extending UIView to easily store CAAnimation and play later, or reverse separately.It can also synchronize the UIView’s frame to the layer’s frame when the animation did finished.

Installation

CocoaPods supported

  • pod ‘EasyAnimationSwift’, ‘~> 0.0.1’

Usage:

  • register:
    someView.register(animation:CAKeyframeAnimation,forkey:String,…)  
    someView.register(animation:[CAKeyframeAnimation],forkey:String,…)

  • play:
    someView.animate(key:String)
    someView.reverse(key:String,totalDuration:Double = 0)

    notice: totalDuration is important to reverse multiple views’ animation as a whole,plz read the demo for more details.

  • remove
    someView.remove(key:String)
Demo GIF

image

Latest podspec

{
    "name": "EasyAnimationSwift",
    "version": "0.0.1",
    "summary": "register CAAnimation that you can play and reverse later",
    "description": "Encapsulation of CAAnimation in swift, extending UIView to easily store CAAnimation and play later, or reverse separately.It can also synchronize the UIView's frame to the layer's frame when the animation did finished.",
    "homepage": "https://github.com/royliu1990/EasyAnimationSwift",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "royliu1990": "[email protected]"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source": {
        "git": "https://github.com/royliu1990/EasyAnimationSwift.git",
        "tag": "0.0.1"
    },
    "source_files": "EasyAnimationSwift",
    "requires_arc": true,
    "dependencies": {
        "RxSwift": [
            "~> 3.0"
        ],
        "RxCocoa": [
            "~> 3.0"
        ],
        "RxOptional": [
            "~> 3.1"
        ]
    },
    "pushed_with_swift_version": "3.0"
}

Pin It on Pinterest

Share This