Fix delayed emit replay scheduling and PgUp/PgDn list jump
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
// Maintainer-controlled web client version.
|
// Maintainer-controlled web client version.
|
||||||
// Format: YYYY.MM.DD Rn (example: 2026.02.20 R2)
|
// Format: YYYY.MM.DD Rn (example: 2026.02.20 R2)
|
||||||
window.CHGRID_WEB_VERSION = "2026.02.28 R304";
|
window.CHGRID_WEB_VERSION = "2026.02.28 R305";
|
||||||
// Optional display timezone for timestamps. Falls back to America/Detroit if unset/invalid.
|
// Optional display timezone for timestamps. Falls back to America/Detroit if unset/invalid.
|
||||||
window.CHGRID_TIME_ZONE = "America/Detroit";
|
window.CHGRID_TIME_ZONE = "America/Detroit";
|
||||||
|
|||||||
@@ -238,9 +238,6 @@ export class ItemEmitRuntime {
|
|||||||
}
|
}
|
||||||
const nextRates = resolveEmitRates(item);
|
const nextRates = resolveEmitRates(item);
|
||||||
output.loopDelaySeconds = resolveEmitLoopDelaySeconds(item);
|
output.loopDelaySeconds = resolveEmitLoopDelaySeconds(item);
|
||||||
if (output.element.paused && output.element.ended) {
|
|
||||||
this.nextEmitStartAtMs.set(itemId, Date.now() + output.loopDelaySeconds * 1000);
|
|
||||||
}
|
|
||||||
setElementPreservesPitch(output.element, nextRates.preservePitch);
|
setElementPreservesPitch(output.element, nextRates.preservePitch);
|
||||||
const nextPlaybackRate = nextRates.playbackRate;
|
const nextPlaybackRate = nextRates.playbackRate;
|
||||||
if (Math.abs(output.element.playbackRate - nextPlaybackRate) > 0.001) {
|
if (Math.abs(output.element.playbackRate - nextPlaybackRate) > 0.001) {
|
||||||
|
|||||||
@@ -355,7 +355,8 @@ export function createItemPropertyEditor(deps: EditorDeps): {
|
|||||||
|
|
||||||
if (code === 'PageUp' || code === 'PageDown') {
|
if (code === 'PageUp' || code === 'PageDown') {
|
||||||
const length = deps.state.itemPropertyOptionValues.length;
|
const length = deps.state.itemPropertyOptionValues.length;
|
||||||
const delta = code === 'PageUp' ? -10 : 10;
|
const jump = Math.min(10, Math.max(1, length - 1));
|
||||||
|
const delta = code === 'PageUp' ? -jump : jump;
|
||||||
const nextIndex = (deps.state.itemPropertyOptionIndex + delta + length * 1000) % length;
|
const nextIndex = (deps.state.itemPropertyOptionIndex + delta + length * 1000) % length;
|
||||||
deps.state.itemPropertyOptionIndex = nextIndex;
|
deps.state.itemPropertyOptionIndex = nextIndex;
|
||||||
deps.updateStatus(deps.state.itemPropertyOptionValues[nextIndex]);
|
deps.updateStatus(deps.state.itemPropertyOptionValues[nextIndex]);
|
||||||
|
|||||||
Reference in New Issue
Block a user