@twick/core 0.15.16 → 0.15.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +5 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -0
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -4663,12 +4663,14 @@ var Player = class {
|
|
|
4663
4663
|
const state = await this.prepare();
|
|
4664
4664
|
const previousState = this.playback.state;
|
|
4665
4665
|
this.playback.state = state.paused ? 2 /* Paused */ : 0 /* Playing */;
|
|
4666
|
+
let didSeekWhilePaused = false;
|
|
4666
4667
|
if (state.seek >= 0 || !this.isInUserRange(this.status.frame)) {
|
|
4667
4668
|
const seekFrame = state.seek < 0 ? this.status.frame : state.seek;
|
|
4668
4669
|
const clampedFrame = this.clampRange(seekFrame);
|
|
4669
4670
|
this.logger.profile("seek time");
|
|
4670
4671
|
await this.playback.seek(clampedFrame);
|
|
4671
4672
|
this.logger.profile("seek time");
|
|
4673
|
+
didSeekWhilePaused = state.paused;
|
|
4672
4674
|
} else if (state.paused) {
|
|
4673
4675
|
if (state.render || state.paused && previousState !== 2 /* Paused */) {
|
|
4674
4676
|
await this.render.dispatch();
|
|
@@ -4684,6 +4686,9 @@ var Player = class {
|
|
|
4684
4686
|
}
|
|
4685
4687
|
await this.render.dispatch();
|
|
4686
4688
|
this.frame.current = this.playback.frame;
|
|
4689
|
+
if (didSeekWhilePaused) {
|
|
4690
|
+
this.requestRender();
|
|
4691
|
+
}
|
|
4687
4692
|
this.request();
|
|
4688
4693
|
}
|
|
4689
4694
|
request() {
|