1 line
3.3 KiB
Plaintext
1 line
3.3 KiB
Plaintext
|
|
{"version":3,"file":"FederatedPointerEvent.mjs","sources":["../src/FederatedPointerEvent.ts"],"sourcesContent":["import { FederatedMouseEvent } from './FederatedMouseEvent';\n\n/**\n * A {@link PIXI.FederatedEvent} for pointer events.\n * @memberof PIXI\n */\nexport class FederatedPointerEvent extends FederatedMouseEvent implements PointerEvent\n{\n /**\n * The unique identifier of the pointer.\n * @see {@link https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/pointerId}\n */\n public pointerId: number;\n\n /**\n * The width of the pointer's contact along the x-axis, measured in CSS pixels.\n * radiusX of TouchEvents will be represented by this value.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/width\n */\n public width = 0;\n\n /**\n * The height of the pointer's contact along the y-axis, measured in CSS pixels.\n * radiusY of TouchEvents will be represented by this value.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/height\n */\n public height = 0;\n\n /**\n * Indicates whether or not the pointer device that created the event is the primary pointer.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/isPrimary\n */\n public isPrimary = false;\n\n /**\n * The type of pointer that triggered the event.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/pointerType\n */\n public pointerType: string;\n\n /**\n * Pressure applied by the pointing device during the event.\n *s\n * A Touch's force property will be represented by this value.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/pressure\n */\n public pressure: number;\n\n /**\n * Barrel pressure on a stylus pointer.\n * @see https://w3c.github.io/pointerevents/#pointerevent-interface\n */\n public tangentialPressure: number;\n\n /**\n * The angle, in degrees, between the pointer device and the screen.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/tiltX\n */\n public tiltX: number;\n\n /**\n * The angle, in degrees, between the pointer device and the screen.\n * @see https://developer.mozilla.org/en-US/docs/Web/API/PointerEvent/tiltY\n */\n public tiltY: number;\n\n /**\n * Twist of a stylus pointer.\n * @see https://w3c.github.io/pointerevents/#pointerevent-interface\n */\n public twist: number;\n\n /** This is the number of clicks that occurs in 200ms/click of each other. */\n public detail: number;\n\n // Only included for completeness for now\n getCoalescedEvents(): PointerEvent[]\n {\n if (this.type === 'pointermove' || this.type === 'mousemove' || this.type === 'touchmove')\n {\n return [this];\n }\n\n return [];\n }\n\n // Only included for completeness for now\n getPredictedEvents(): PointerEvent[]\n {\n throw new Error('getPredictedEvents is not supported!');\n }\n}\n"],"names":[],"mappings":";AAMO,MAAM,8BAA8B,oBAC3C;AAAA,EADO,cAAA;AAAA,UAAA,GAAA,SAAA,GAaH,KAAO,QAAQ,GAOf,KAAO,SAAS,GAMhB,KAAO,YAAY;AAAA,EAAA;AAAA;AAAA,EA4CnB,qBACA;AACI,WAAI,KAAK,SAAS,iBAAiB,KAAK,SAAS,eAAe,KAAK,SAAS,cAEnE,CAAC,IAAI,IAGT,CAAA;AAAA,EACX;AAAA;AAAA,EAGA,qBACA;AACU,UAAA,IAAI,MAAM,sCAAsC;AAAA,EAC1D;AACJ;"}
|