fromWire static method

SceneCorners fromWire(
  1. Object? value
)

Implementation

static SceneCorners fromWire(Object? value) => switch (value) {
  num n => SceneCorners.all(n.toDouble()),
  List l when l.length == 4 && l.every((e) => e is num) => SceneCorners(
    topLeft: (l[0] as num).toDouble(),
    topRight: (l[1] as num).toDouble(),
    bottomRight: (l[2] as num).toDouble(),
    bottomLeft: (l[3] as num).toDouble(),
  ),
  _ => zero,
};