cancel method
- Duration timeStamp = Duration.zero,
End the gesture by canceling the pointer (as would happen if the system showed a modal dialog on top of the Flutter application, for instance).
Implementation
Future<void> cancel({ Duration timeStamp = Duration.zero }) {
assert(_pointer.kind != PointerDeviceKind.trackpad, 'Trackpads do not send cancel events.');
return TestAsyncUtils.guard<void>(() async {
assert(_pointer._isDown);
await _dispatcher(_pointer.cancel(timeStamp: timeStamp));
assert(!_pointer._isDown);
});
}