copyWith method

  1. @override
StackDrawItem copyWith({
  1. Size? size,
  2. Offset? offset,
  3. double? angle,
  4. StackItemStatus? status,
  5. bool? lockZOrder,
  6. DrawItemContent? content,
})
override

Update content and return new instance

Implementation

@override
StackDrawItem copyWith({
  Size? size,
  Offset? offset,
  double? angle,
  StackItemStatus? status,
  bool? lockZOrder,
  DrawItemContent? content,
}) {
  return StackDrawItem(
    id: id,
    size: size ?? this.size,
    offset: offset ?? this.offset,
    angle: angle ?? this.angle,
    status: status ?? this.status,
    lockZOrder: lockZOrder ?? this.lockZOrder,
    content: content ?? this.content,
  );
}