computeScaleSlop function Null safety

double computeScaleSlop (
  1. PointerDeviceKind kind
)

Determine the approriate scale slop pixels based on the kind of pointer.

Implementation

double computeScaleSlop(PointerDeviceKind kind) {
  switch (kind) {
    case PointerDeviceKind.mouse:
      return kPrecisePointerScaleSlop;
    case PointerDeviceKind.stylus:
    case PointerDeviceKind.invertedStylus:
    case PointerDeviceKind.unknown:
    case PointerDeviceKind.touch:
      return kScaleSlop;
  }
}