Luxar Viewer API Documentation - v2026.9.22
    Preparing search index...

    Register window-focus and document-visibility listeners that pause / resume the animation loop as the page goes background and back. Both listeners early-return when FocusHandlingPorts.getRecordingPanel reports an active capture, so offline recording keeps a stable loop.

    getRecordingPanel is a live accessor (not a snapshot) so a focus event that fires mid-dispose — after the orchestrator cleared its recordingPanel field but before events.dispose() removes the listener — sees the updated undefined and the optional-chain short-circuits, matching the original this.recordingPanel?.… behaviour.

    Routed through the supplied EventGroup so the listeners are cleaned up on dispose.

    interface FocusHandlingPorts {
        events: EventGroup;
        animationController: AnimationController;
        getRecordingPanel: () => RecordingPanel | undefined;
    }
    Index
    events: EventGroup
    animationController: AnimationController
    getRecordingPanel: () => RecordingPanel | undefined