mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-22 07:29:08 +00:00
fix: reset timers
reset timers correctly when current event is deleted
This commit is contained in:
@@ -1066,8 +1066,8 @@ export class EventTimer extends Timer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
unload() {
|
unload() {
|
||||||
// reset duration
|
// reset timer
|
||||||
this.duration = null;
|
this._resetTimers(true);
|
||||||
|
|
||||||
// reset selected
|
// reset selected
|
||||||
this._resetSelection();
|
this._resetSelection();
|
||||||
|
|||||||
@@ -120,6 +120,7 @@ export class Timer {
|
|||||||
_resetTimers(total = false) {
|
_resetTimers(total = false) {
|
||||||
if (total) this.duration = null;
|
if (total) this.duration = null;
|
||||||
this.current = this.duration;
|
this.current = this.duration;
|
||||||
|
this.running = null;
|
||||||
this.secondaryTimer = null;
|
this.secondaryTimer = null;
|
||||||
this._finishAt = null;
|
this._finishAt = null;
|
||||||
this._finishedAt = null;
|
this._finishedAt = null;
|
||||||
|
|||||||
Reference in New Issue
Block a user