dragTo method Null safety

Future<void> dragTo(
  1. {required int x,
  2. required int y,
  3. Duration? duration,
  4. MouseTween? tween,
  5. MouseButton? button}
)

drags mouse cursor to a certain position , returns Future<void>

Implementation

static Future<void> dragTo({
  required int x,
  required int y,
  Duration? duration,
  MouseTween? tween,
  MouseButton? button,
}) async {
  await Process.run('python3', [
    mPath,
    'drag_to',
    x.toString(),
    y.toString(),
    duration != null ? duration.inSeconds.toString() : '0',
    _mapTween(tween),
    _mapButton(button),
  ]);
}