diff --git a/lib/pages/interval_page.dart b/lib/pages/interval_page.dart index 04a0f49..26bf35b 100644 --- a/lib/pages/interval_page.dart +++ b/lib/pages/interval_page.dart @@ -43,9 +43,8 @@ class _IntervalTimerPageState extends State { await showDialog( context: context, builder: (BuildContext context) { - return const StartTimerPopup( + return const TimerStartStopPopup( title: 'Motivation vor dem Training', - text: 'Du gehörst zu Gruppe', ); }, ); @@ -73,9 +72,8 @@ class _IntervalTimerPageState extends State { showDialog( context: context, builder: (BuildContext context) { - return const StartTimerPopup( + return const TimerStartStopPopup( title: 'Motivation nach dem Training', - text: 'Du gehörst zu Gruppe', ); }, ); diff --git a/lib/widgets/popup_for_start_and_stop.dart b/lib/widgets/popup_for_start_and_stop.dart index b51baff..097e587 100644 --- a/lib/widgets/popup_for_start_and_stop.dart +++ b/lib/widgets/popup_for_start_and_stop.dart @@ -3,26 +3,23 @@ import 'package:smoke_cess_app/widgets/slider.dart'; import 'package:smoke_cess_app/widgets/submit_form_button.dart'; import 'package:smoke_cess_app/widgets/text_formfield.dart'; -class StartTimerPopup extends StatefulWidget { +class TimerStartStopPopup extends StatefulWidget { final String title; - final String text; - const StartTimerPopup({Key? key, required this.title, required this.text}) - : super(key: key); + const TimerStartStopPopup({Key? key, required this.title}) : super(key: key); @override - _StartTimerPopupState createState() => _StartTimerPopupState(); + TimerStartStopPopupState createState() => TimerStartStopPopupState(); } -class _StartTimerPopupState extends State { +class TimerStartStopPopupState extends State { final MySlider slider = const MySlider(); - String _textInput = ''; void submitForm(BuildContext context) { Navigator.of(context).pop(); } - void onFormFieldSave(String? newValue) => _textInput = newValue!; + void onFormFieldSave(String? newValue) => newValue!; @override Widget build(BuildContext context) {