DeviceGestureSettings.fromWindow constructor Null safety
- FlutterView window
Create a new DeviceGestureSettings from the provided window
.
Implementation
factory DeviceGestureSettings.fromWindow(ui.FlutterView window) {
final double? physicalTouchSlop = window.viewConfiguration.gestureSettings.physicalTouchSlop;
return DeviceGestureSettings(
touchSlop: physicalTouchSlop == null ? null : physicalTouchSlop / window.devicePixelRatio
);
}