AnimationOptions class

Options common to map movement methods that involve animation, such as {@link MapboxMap#panBy} and {@link MapboxMap#easeTo}, controlling the duration and easing function of the animation. All properties are optional.

@typedef {Object} AnimationOptions @property {number} duration The animation's duration, measured in milliseconds. @property {Function} easing A function taking a time in the range 0..1 and returning a number where 0 is the initial state and 1 is the final state. @property {PointLike} offset of the target center relative to real map container center at the end of animation. @property {boolean} animate If false, no animation will occur. @property {boolean} essential If true, then the animation is considered essential and will not be affected by prefers-reduced-motion.

Constructors

AnimationOptions({num? duration, num easing(num time)?, required Point offset, bool? animate, bool? essential})
factory
AnimationOptions.fromJsObject(AnimationOptionsJsImpl jsObject)
Creates a new AnimationOptions from a jsObject.

Properties

animate bool
no setter
duration num
no setter
easing num Function(num time)
no setter
essential bool
no setter
hashCode int
The hash code for this object.
no setterinherited
jsObject → AnimationOptionsJsImpl
JS object.
finalinherited
offset Point
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited