seed update, action prep, titleization

This commit is contained in:
Joshua Burman
2024-12-24 14:41:39 -05:00
parent ffd696053a
commit c6030f8ac5
23 changed files with 4881 additions and 210 deletions

View File

@ -10,6 +10,7 @@ class ActivityTimerModel with ChangeNotifier {
ActivityModel? _activityModel;
Activity? _activity;
List _sets = [];
List _actions = [];
int _currentActionNum = 0;
int _currentSetNum = 0;
Timer? _periodicTimer;
@ -30,7 +31,7 @@ class ActivityTimerModel with ChangeNotifier {
double get progress => _progress;
int get totalTime => _totalTime;
void setup(ActivityModel activityModel, Activity activity) {
void setup(ActivityModel activityModel, Activity activity, List actions) {
if (_activityModel == null || activityModel.id != _activityModel?.id) {
_periodicTimer?.cancel();
_progress = 0;
@ -38,6 +39,7 @@ class ActivityTimerModel with ChangeNotifier {
_activityModel = activityModel;
_activity = activity;
_sets = activityModel.actions[0].items();
_actions = actions;
_currentActionNum = 0;
_currentSetNum = 0;
setActionCount();