API Docs for: 2.0.0

Class Pointer

Class defined in: public/src/pointer.js:18

Graphical representation of a pointer, using Snap.svg and SVG

changeMode( mode )
public/src/pointer.js:204

Switch between window manipulation and application interaction

Parameters:
  • mode <Number>

    new pointer mode: 0 window manipulation, 1 application interaction

colorSVG( svg, stroke, fill )
public/src/pointer.js:301

Utility function to modify the color of SVG elememts

Parameters:
init( id, label, color, width, height )
public/src/pointer.js:41

Init method, creates a div to attach Snap rendering into it

Parameters:
  • id <String>

    id of the div supporting the pointer

  • label <String>

    label for the username

  • color <String>

    color for the pointer

  • width <Number>

    width in pixel

  • height <Number>

    height in pixel

setColor( color )
public/src/pointer.js:166

Change the color of the pointer

Parameters:
  • color <String>

    color for the pointer

setLabel( label )
public/src/pointer.js:177

Change the label of the pointer (user name)

Parameters:
  • label <String>

    label for the username

setSourceType( type )
public/src/pointer.js:193

Change the type of pointer: touch, mouse, ...

Parameters:
  • type <String>

    new type of pointer

updateBox( scale )
public/src/pointer.js:215

Recalculate the boxe around the pointer label

Parameters:
  • scale <Number>

    new scale for client -1

updateIconColors( )
public/src/pointer.js:225

Update the colors based on mode and type