@reactoo/watchtogether-sdk-js 2.5.61 → 2.5.62
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/package.json
CHANGED
|
@@ -15,7 +15,7 @@ const syncModule = function ({room, emitter} = {}) {
|
|
|
15
15
|
};
|
|
16
16
|
const syncDefaultWaitTime = 60000;
|
|
17
17
|
const syncShortWaitTime = 10000;
|
|
18
|
-
const maxSyncThreshold = 0.
|
|
18
|
+
const maxSyncThreshold = 0.5;
|
|
19
19
|
const maxSyncTries = 3;
|
|
20
20
|
const waitForPlayingEventAfterSeek = 5000;
|
|
21
21
|
const fastForwardThreshold = 4
|
|
@@ -71,11 +71,13 @@ const syncModule = function ({room, emitter} = {}) {
|
|
|
71
71
|
|
|
72
72
|
};
|
|
73
73
|
|
|
74
|
-
const stopSyncLoop = () => {
|
|
74
|
+
const stopSyncLoop = (doNotResetRetryCount) => {
|
|
75
75
|
room._log('--- Sync disabled ---');
|
|
76
76
|
clearTimeout(syncWaitId);
|
|
77
77
|
syncWaitId = null;
|
|
78
|
-
|
|
78
|
+
if(!doNotResetRetryCount) {
|
|
79
|
+
currentSyncRetry = 0
|
|
80
|
+
}
|
|
79
81
|
stopFlag = true;
|
|
80
82
|
};
|
|
81
83
|
|
|
@@ -374,7 +376,7 @@ const syncModule = function ({room, emitter} = {}) {
|
|
|
374
376
|
const handleBuffering = () => {
|
|
375
377
|
room._log('handleBuffering');
|
|
376
378
|
if(!isProgrammaticallySeeked) {
|
|
377
|
-
stopSyncLoop();
|
|
379
|
+
stopSyncLoop(true);
|
|
378
380
|
clientPaused().catch(() => {});
|
|
379
381
|
isPreloading = _playerInterface.isPaused;
|
|
380
382
|
}
|