Description

Lock the keys on the canvas and avoid scrolling of the page

Usage

Parameters

  • canvas {HTMLCanvasElement}

    Canvas

  • focus_start {Boolean} optional

    (optional) Place the focus on the canvas. false by default

  • onFocus {Function} optional

    (optional) Callback when the canvas is the focus

  • onBlur {Function} optional

    (optional) Callback when the canvas loses the focus

Discussion