Class Canvas
Represents a wrap object for a canvas HTML5 element.
Defined in: benchgl.js.
Constructor Attributes | Constructor Name and Description |
---|---|
Canvas(canvas, options)
Creates a new Canvas.
|
Method Attributes | Method Name and Description |
---|---|
onKeyDown(e)
Handles the 'keydown' event, if supplied.
|
|
onKeyUp(e)
Handles the 'keyup' event, if supplied.
|
|
onMouseDown(e)
Handles the 'mousedown' event, if supplied.
|
|
onMouseMove(e)
Handles the 'mousemove' event, if supplied.
|
|
onMouseUp(e)
Handles the 'mouseup' event, if supplied.
|
|
onMouseWheel(e)
Handles the 'mousewheel' event, if supplied.
|
Class Detail
Canvas(canvas, options)
Creates a new Canvas.
- Parameters:
- {HTMLCanvasElement} canvas
- The canvas element.
- options
Method Detail
onKeyDown(e)
Handles the 'keydown' event, if supplied.
- Parameters:
- {Event} e
- Information about the event occured.
onKeyUp(e)
Handles the 'keyup' event, if supplied.
- Parameters:
- {Event} e
- Information about the event occured.
onMouseDown(e)
Handles the 'mousedown' event, if supplied.
- Parameters:
- {Event} e
- Information about the event occured.
onMouseMove(e)
Handles the 'mousemove' event, if supplied.
- Parameters:
- {Event} e
- Information about the event occured.
onMouseUp(e)
Handles the 'mouseup' event, if supplied.
- Parameters:
- {Event} e
- Information about the event occured.
onMouseWheel(e)
Handles the 'mousewheel' event, if supplied.
- Parameters:
- {Event} e
- Information about the event occured.