seed update, action prep, titleization
This commit is contained in:
@ -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();
|
||||
|
Reference in New Issue
Block a user