copyWith method

  1. @override
InsanichessOtbSettings copyWith({
  1. bool? rotateChessboard,
  2. bool? mirrorTopPieces,
  3. bool? allowUndo,
  4. bool? alwaysPromoteToQueen,
  5. AutoZoomOutOnMoveBehaviour? autoZoomOutOnMove,
})
override

Returns a new InsanichessOtbSettings object by overriding existing field values with those given in arguments.

Implementation

@override
InsanichessOtbSettings copyWith({
  bool? rotateChessboard,
  bool? mirrorTopPieces,
  bool? allowUndo,
  bool? alwaysPromoteToQueen,
  AutoZoomOutOnMoveBehaviour? autoZoomOutOnMove,
}) {
  return InsanichessOtbSettings(
    rotateChessboard: rotateChessboard ?? this.rotateChessboard,
    mirrorTopPieces: mirrorTopPieces ?? this.mirrorTopPieces,
    allowUndo: allowUndo ?? this.allowUndo,
    alwaysPromoteToQueen: alwaysPromoteToQueen ?? this.alwaysPromoteToQueen,
    autoZoomOutOnMove: autoZoomOutOnMove ?? this.autoZoomOutOnMove,
  );
}