animate static method

bool animate(
  1. ViewableWidgetMixin model,
  2. String caller,
  3. String propertyOrFunction,
  4. List arguments,
)

Implementation

static bool animate(ViewableWidgetMixin model, String caller,
    String propertyOrFunction, List<dynamic> arguments) {
  var animations = model.animations;
  if (animations != null) {
    var id = elementAt(arguments, 0);
    AnimationModel? animation;
    if (!isNullOrEmpty(id)) {
      var list = animations.where((animation) => animation.id == id);
      if (list.isNotEmpty) animation = list.first;
    } else {
      animation = animations.first;
    }
    animation?.execute(caller, propertyOrFunction, arguments);
  }
  return true;
}