/* COPYRIGHT Esri - https://js.arcgis.com/5.1.2/LICENSE.txt */
import{InputHandler as t}from"../InputHandler.js";class i extends t{constructor(t){super(!0),this._onChange=t,this._value="mouse",this._x=null,this._y=null,this._id=null,this.registerIncoming("pointer-move",t=>this._update(t.data))}_update(t){const i=t.native.pointerType,s="touch"===i?"touch":"pen"===i?"pen":"mouse",{x:e,y:n,native:{pointerId:h}}=t;s===this._value&&this._x===e&&this._y===n&&this._id===h||(this._value=s,this._x=e,this._y=n,this._id=h,this._onChange(h,s,e,n))}}export{i as LatestPointer};
