RotationAnimation

fun <T : ComponentView> RotationAnimation(    componentView: T,     byAngle: Double = 0.0,     duration: Int = 1000)

A rotation animation. Rotates given ComponentView to given angle.

Parameters

componentView

ComponentView to animate

byAngle

relative angle. Default: 0

duration

Animation duration in milliseconds. Default: 1 second


fun <T : ComponentView> RotationAnimation(    componentView: T,     fromAngle: Number = componentView.rotation,     toAngle: Number = componentView.rotation,     duration: Int = DEFAULT_ANIMATION_DURATION)

Creates a RotationAnimation for the given ComponentView.

Parameters

T

Generic ComponentView.

componentView

ComponentView to animate.

fromAngle

Initial angle. Default: Current ComponentView.rotation.

toAngle

Resulting angle. Default: Current ComponentView.rotation.

duration

Duration in milliseconds. Default: DEFAULT_ANIMATION_DURATION.