V45.17: fix seek khi play master FX active - set startOffsetTimeRef + __fxRtPlayheadFreeze NGAY tai click (het 50ms dau playhead chay theo processed anchor cu truoc khi dung) v=202608311151

This commit is contained in:
2026-08-31 11:52:23 +07:00
parent 80b8c3e034
commit 8ccf7e4b14
3 changed files with 11 additions and 6 deletions
+4 -1
View File
@@ -19405,11 +19405,14 @@ const App = () => {
const applyPlayheadDirect = (time) => {
localSelectionAnchorRef.current = time;
if (isPlaying) {
// V45.17: seek khi đang play — startOffset + freeze NGAY: playhead nhảy
// tới click + đứng tại đó (không chạy theo processed anchor cũ 50ms).
startOffsetTimeRef.current = time;
setCurrentTime(time);
fxRtKeepForRestart = true; // restart/resume — giữ session FX realtime
stopAllPlayback();
try { if (window.__fxRtPlayheadFreeze) window.__fxRtPlayheadFreeze(true); } catch (e) { }
setTimeout(() => {
startOffsetTimeRef.current = time;
startAudioTimeRef.current = getAudioContext().currentTime;
startTrackPlayback(time);
setIsPlaying(true);
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -51,7 +51,7 @@
<script src="/static/js/services/promptTemplateManager.js?v=202608290945"></script>
<script src="/static/js/services/undoRedoEngine.js?v=202608290945"></script>
<script src="/static/js/services/chordTheory.js?v=202608290945"></script>
<script src="/static/js/app.precompiled.js?v=202608311143" defer></script>
<script src="/static/js/app.precompiled.js?v=202608311151" defer></script>
<link rel="stylesheet" href="/static/css/styles.css?v=202608290945">
<style>
:root {