-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
Excellent plugin. Is it possible to add a loop to the controller also? My use case is this: I have a download operation in progress when a button is clicked using Icons.refresh_outlined icon button. It needs to spin till the action is complete.
I created an animation controller
_controller = AnimationController(
vsync: this, // the SingleTickerProviderStateMixin
duration: Duration(seconds: 1),
);
and the button as
AnimatedIconButton(
animationController: _controller,
icons: [
AnimatedIconItem(
icon: Icon(
Icons.refresh_outlined,
color: Colors.white,
),
onPressed: () async {
// _controller.forward();
_controller.loop(count: 10);
print("start");
await InstallQuestions().Do();
await Future.delayed(Duration(seconds: 3));
print("end");
_controller.stop();
},
),
],
),
The plugin seems to ignore loop. Is that correct?
Metadata
Metadata
Assignees
Labels
No labels