fix(piano-roll): seek-to-start restarts playback
- Add seekPlaybackTo(time) that stops, updates refs, reschedules MIDI, and restarts playback for both sub-tab and main timeline - 'Quay lại đầu' and 'Đầu vùng chọn' buttons use seekPlaybackTo
This commit is contained in:
@@ -261,6 +261,11 @@
|
||||
- **Các file ảnh hưởng:** `app/static/js/app.jsx`, `app/static/js/services/soundfontPlayer.js`, `app/static/js/app.precompiled.js`
|
||||
- **Ghi chú/Test (nếu có):** `npm run build` pass.
|
||||
|
||||
### [2026-07-26 12:20] Task: Fix Piano Roll seek-to-start during playback
|
||||
- **Tóm tắt thay đổi:** Thêm hàm `seekPlaybackTo(time)` xử lý seek khi đang play cho cả sub-tab và main timeline. Nút "Quay lại đầu" (`skip-back`) và "Đầu vùng chọn" (`step-back`) giờ restart playback từ vị trí mới: stop → update refs → reschedule MIDI → restart.
|
||||
- **Các file ảnh hưởng:** `app/static/js/app.jsx`, `app/static/js/app.precompiled.js`
|
||||
- **Ghi chú/Test (nếu có):** `npm run build` pass.
|
||||
|
||||
### [2026-07-26 12:13] Task: Fix Piano Roll loop/stop behavior
|
||||
- **Tóm tắt thay đổi:** (1) Sub-tab loop selection chỉ active khi nút Loop (st.isLooping) bật — không còn bị ảnh hưởng bởi global isLoopingSelection. (2) Stop dừng ngay lập tức: `SonicSF.stopAll()` set gain 0 và stop oscillator tại ctx.currentTime, không ramp.
|
||||
- **Các file ảnh hưởng:** `app/static/js/app.jsx`, `app/static/js/services/soundfontPlayer.js`, `app/static/js/app.precompiled.js`
|
||||
|
||||
Reference in New Issue
Block a user