Documentation
    Preparing search index...

    Interface GamepadServiceOptions

    Host hooks for focus-scoped controller delivery; no device handles cross the wire.

    interface GamepadServiceOptions {
        cancelFrame?: (frame: number) => void;
        getFocusedWindow?: () => string | null;
        isHostActive?: () => boolean;
        now?: () => number;
        readGamepads?: () => readonly (GamepadPadSample | null)[];
        requestFrame?: (callback: () => void) => number;
        subscribeChanges?: (refresh: () => void) => () => void;
    }
    Index

    Properties

    cancelFrame?: (frame: number) => void
    getFocusedWindow?: () => string | null

    Return the host's current input owner; never use a napplet-supplied id.

    isHostActive?: () => boolean

    Whether the host surface is visible and focused.

    now?: () => number
    readGamepads?: () => readonly (GamepadPadSample | null)[]
    requestFrame?: (callback: () => void) => number
    subscribeChanges?: (refresh: () => void) => () => void

    Focus, visibility and connection events should refresh immediately.