@@ -2,19 +2,9 @@ import 'package:flutter/foundation.dart';
22import 'package:flutter/widgets.dart' ;
33import '../flutter_animate.dart' ;
44
5- /// An Effect that is composed of or more other existing Effects. Provides
6- /// syntactic sugar for calling the `composeEffects` method.
7- abstract class CompositeEffect extends Effect {
8- const CompositeEffect ({super .delay, super .duration, super .curve});
9-
10- @protected
11- List <Effect > get effects;
12-
13- @override
14- Widget build (BuildContext context, Widget child, AnimationController controller, EffectEntry entry) =>
15- composeEffects (effects, context, child, controller, entry);
16- }
17-
5+ /// Used to easily create effects that are composed of one or more existing Effects. Provides
6+ /// syntactic sugar for overrideing build and calling the `composeEffects` method
7+ /// with a list of effects.
188mixin CompositeEffectMixin on Effect {
199 List <Effect > get effects;
2010
@@ -51,7 +41,7 @@ class BeginEndEffect<T> extends Effect {
5141///
5242/// It can be instantiated and added to Animate, but has no visual effect.
5343@immutable
54- abstract class Effect <T > {
44+ class Effect <T > {
5545 const Effect ({this .delay, this .duration, this .curve});
5646
5747 /// The specified delay for the effect. If null, will use the delay from the
@@ -77,7 +67,7 @@ abstract class Effect<T> {
7767 return child;
7868 }
7969
80- /// Calls build on one or more effects, composing them together and returning the resulting widget tree
70+ /// Calls build on one or more effects, composing them together and returning the resulting widget tree.
8171 @protected
8272 Widget composeEffects (
8373 List <Effect > effects,
0 commit comments