These docs are for Phaser 2.3.0 Phaser 3 docs can be found on GitHub pages.
Phaser CE docs can be found on the Phaser CE Documentation site.

Constructor

Phaser. MSPointer

new MSPointer(game)

The MSPointer class handles Microsoft touch interactions with the game and the resulting Pointer objects.

It will work only in Internet Explorer 10 and Windows Store or Windows Phone 8 apps using JavaScript. http://msdn.microsoft.com/en-us/library/ie/hh673557(v=vs.85).aspx

Parameters
Name Type Description
game Phaser.Game

A reference to the currently running game.

Source code: input/MSPointer.js (Line 17)

Public Properties

button

Properties:
Name Type Description
button- number

The type of click, either: Phaser.Mouse.NO_BUTTON, Phaser.Mouse.LEFT_BUTTON, Phaser.Mouse.MIDDLE_BUTTON or Phaser.Mouse.RIGHT_BUTTON.

Source code: input/MSPointer.js (Line 53)

callbackContext : Object

The context under which callbacks are called (defaults to game).

Source code: input/MSPointer.js (Line 27)

capture : boolean

If true the Pointer events will have event.preventDefault applied to them, if false they will propagate fully.

Source code: input/MSPointer.js (Line 47)

enabled : boolean

MSPointer input will only be processed if enabled.

Default Value
  • true
Source code: input/MSPointer.js (Line 68)

event :MSPointerEvent | null

The browser MSPointer DOM event. Will be null if no event has ever been received. Access this property only inside a Pointer event handler and do not keep references to it.

Type
  • MSPointerEvent | null
Default Value
  • null
Source code: input/MSPointer.js (Line 61)

game : Phaser.Game

A reference to the currently running game.

Source code: input/MSPointer.js (Line 22)

pointerDownCallback : Function

A callback that can be fired on a MSPointerDown event.

Source code: input/MSPointer.js (Line 32)

pointerMoveCallback : Function

A callback that can be fired on a MSPointerMove event.

Source code: input/MSPointer.js (Line 37)

pointerUpCallback : Function

A callback that can be fired on a MSPointerUp event.

Source code: input/MSPointer.js (Line 42)

Public Methods

onPointerDown(event)

The function that handles the PointerDown event.

Parameters
Name Type Description
event PointerEvent

The native DOM event.

Source code: input/MSPointer.js (Line 135)

onPointerMove(event)

The function that handles the PointerMove event.

Parameters
Name Type Description
event PointerEvent

The native DOM event.

Source code: input/MSPointer.js (Line 168)

onPointerUp(event)

The function that handles the PointerUp event.

Parameters
Name Type Description
event PointerEvent

The native DOM event.

Source code: input/MSPointer.js (Line 198)

start()

Starts the event listeners running.

Source code: input/MSPointer.js (Line 92)

stop()

Stop the event listeners.

Source code: input/MSPointer.js (Line 230)