_pointerDataHandler (x, y, isClicking, dataDelta) {
    // Get the new coordinates.
    const newCoordinates = this.getCoordinates(x, y, dataDelta)

    // Only emit the pointermove event if the coordinates have actually changed.
    if (!this.coordinates.equalsTo(newCoordinates)) {
      this.emit(EVENT.POINTER_MOVE, newCoordinates)
      this.coordinates.update(newCoordinates)
    }

    // Check if isClicking has changed since the last time. If it has, then emit
    // the corresponding pointer event.
    if (isClicking !== this.isClicking) {
      if (isClicking) {
        this.emit(EVENT.POINTER_DOWN)
      } else {
        this.emit(EVENT.POINTER_UP)
      }

      this.isClicking = isClicking
    }
  }
/**
   * Handle incoming coordinate data for the pointer.
   *
   * @private
   * @param {number} x The new x coordinate of the remote.
   * @param {number} y The new y coordinate of the remote.
   * @param {boolean} isClicking If the pointer is clicking.
   * @param {number} dataDelta The time delta in ms since the last message.
   */
Handle incoming coordinate data for the pointer.
@private
@param {number} x The new x coordinate of the remote.
@param {number} y The new y coordinate of the remote.
@param {boolean} isClicking If the pointer is clicking.
@param {number} dataDelta The time delta in ms since the last message.
Handle incoming coordinate data for the pointer . @private @param { number } x The new x coordinate of the remote . @param { number } y The new y coordinate of the remote . @param { boolean } isClicking If the pointer is clicking . @param { number } dataDelta The time delta in ms since the last message .
_pointerDataHandler (x, y, isClicking, dataDelta) {
    const newCoordinates = this.getCoordinates(x, y, dataDelta)
    if (!this.coordinates.equalsTo(newCoordinates)) {
      this.emit(EVENT.POINTER_MOVE, newCoordinates)
      this.coordinates.update(newCoordinates)
    }
    if (isClicking !== this.isClicking) {
      if (isClicking) {
        this.emit(EVENT.POINTER_DOWN)
      } else {
        this.emit(EVENT.POINTER_UP)
      }
      this.isClicking = isClicking
    }
  }
_pointerDataHandler ( x , y , isClicking , dataDelta ) { const newCoordinates = this . getCoordinates ( x , y , dataDelta ) if ( ! this . coordinates . equalsTo ( newCoordinates ) ) { this . emit ( EVENT . POINTER_MOVE , newCoordinates ) this . coordinates . update ( newCoordinates ) } if ( isClicking !== this . isClicking ) { if ( isClicking ) { this . emit ( EVENT . POINTER_DOWN ) } else { this . emit ( EVENT . POINTER_UP ) } this . isClicking = isClicking } }
Handle incoming coordinate data for the pointer.
Handle incoming coordinate data for the pointer .
// Get the new coordinates. // Only emit the pointermove event if the coordinates have actually changed. // Check if isClicking has changed since the last time. If it has, then emit // the corresponding pointer event.