addPointer method
- Duration timeStamp = Duration.zero,
- Offset? location,
- FlutterView? view,
Create a PointerAddedEvent with the PointerDeviceKind the pointer was created with.
By default, the time stamp on the event is Duration.zero. You can give a
specific time stamp by passing the timeStamp argument.
Implementation
PointerAddedEvent addPointer({
Duration timeStamp = Duration.zero,
Offset? location,
FlutterView? view,
}) {
_location = location ?? _location;
return PointerAddedEvent(
viewId: view?.viewId ?? WidgetsBinding.instance.platformDispatcher.implicitView!.viewId,
timeStamp: timeStamp,
kind: kind,
device: _device,
position: _location ?? Offset.zero,
);
}