This is a simple wrapper for linear iOS animations. Currently, only simple animations are supported. We promise to add much more fascination animations to this library, so please bear with us until then :)
Add this line to your application's Gemfile:
gem 'motion-linear-animate'
And then execute:
bundle
A sample app is included for reference. To get it up and running, simply clone the
repository and run rake
or rake device
depending on whether you want
to preview it in the simulator or device.
Here is the basic setup to ease work for you:
animator = MotionAnimator.new
animator.linear_animate(view, to: final_point, duration: time_period, completion: completion_block)
final_point
should be an instance ofCGPoint
or any other object withx
andy
attributes set to the final (x, y) position the view should be in after the animation.time_period
is the duration allocated for the animation to take place.
See the CONTRIBUTING document. Thank you, contributors!
iOS (RubyMotion) Animation Library is Copyright (c) 2016 Multunus Software Pvt. Ltd. It is free software, and may be redistributed under the terms specified in the LICENSE file.
iOS (RubyMotion) Animation Library is maintained and funded by Multunus Software Pvt. Ltd. The names and logos for Multunus are trademarks of Multunus Software Pvt. Ltd.
We love open source software! See our other projects or hire us to help build your product.