ML-5 Measure button needs loading state (#41)

* added

* Version bump

* Fixed indicator initial position

* Revert "Version bump"

This reverts commit 92793e013d.
This commit is contained in:
Vadim 2023-02-19 18:15:36 +03:00 committed by GitHub
parent 1c4e302103
commit e6338157bf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -70,6 +70,8 @@ class _MeteringMeasureButtonState extends State<MeteringMeasureButton> {
), ),
Positioned.fill( Positioned.fill(
child: CircularProgressIndicator( child: CircularProgressIndicator(
/// This key is needed to make indicator start from the same point every time
key: ValueKey(widget.isMetering),
color: Theme.of(context).colorScheme.onSurface, color: Theme.of(context).colorScheme.onSurface,
strokeWidth: Dimens.grid4, strokeWidth: Dimens.grid4,
value: widget.isMetering ? null : 1, value: widget.isMetering ? null : 1,