diff --git a/lib/l10n/app_zh.arb b/lib/l10n/app_zh.arb new file mode 100644 index 000000000..9e26dfeeb --- /dev/null +++ b/lib/l10n/app_zh.arb @@ -0,0 +1 @@ +{} \ No newline at end of file diff --git a/lib/widgets/workouts/gym_mode.dart b/lib/widgets/workouts/gym_mode.dart index f4e04a885..6667ddfa1 100644 --- a/lib/widgets/workouts/gym_mode.dart +++ b/lib/widgets/workouts/gym_mode.dart @@ -336,6 +336,7 @@ class _LogPageState extends State { } Widget getWeightWidget() { + var minPlateWeight = 1.25; return Row( children: [ IconButton( @@ -345,7 +346,7 @@ class _LogPageState extends State { ), onPressed: () { try { - double newValue = double.parse(_weightController.text) - 1.25; + double newValue = double.parse(_weightController.text) - (2 * minPlateWeight); if (newValue > 0) { setState(() { widget._log.weight = newValue; @@ -393,7 +394,7 @@ class _LogPageState extends State { ), onPressed: () { try { - double newValue = double.parse(_weightController.text) + 1.25; + double newValue = double.parse(_weightController.text) + (2 * minPlateWeight); setState(() { widget._log.weight = newValue; _weightController.text = newValue.toString();