copyWith method

ByteArkPlayerConfig copyWith({
  1. ByteArkPlayerLicenseKey? licenseKey,
  2. bool? autoPlay,
  3. bool? control,
  4. bool? seekButtons,
  5. int? seekTime,
  6. ByteArkPlayerItem? playerItem,
  7. bool? fullScreenButton,
  8. bool? settingButton,
  9. ByteArkLighthouseSetting? lighthouseSetting,
  10. ByteArkAdsSettings? adsSettings,
  11. bool? secureSurface,
  12. ByteArkPlayerSubtitleSize? subtitleSize,
  13. bool? subtitleBackgroundEnabled,
  14. int? subtitlePaddingBottomPercentage,
})

Creates a copy of this ByteArkPlayerConfig with the given fields replaced.

Implementation

ByteArkPlayerConfig copyWith({
  ByteArkPlayerLicenseKey? licenseKey,
  bool? autoPlay,
  bool? control,
  bool? seekButtons,
  int? seekTime,
  ByteArkPlayerItem? playerItem,
  bool? fullScreenButton,
  bool? settingButton,
  ByteArkLighthouseSetting? lighthouseSetting,
  ByteArkAdsSettings? adsSettings,
  bool? secureSurface,
  ByteArkPlayerSubtitleSize? subtitleSize,
  bool? subtitleBackgroundEnabled,
  int? subtitlePaddingBottomPercentage,
}) {
  return ByteArkPlayerConfig(
    licenseKey: licenseKey ?? this.licenseKey,
    autoPlay: autoPlay ?? this.autoPlay,
    control: control ?? this.control,
    seekButtons: seekButtons ?? this.seekButtons,
    seekTime: seekTime ?? this.seekTime,
    playerItem: playerItem ?? this.playerItem,
    fullScreenButton: fullScreenButton ?? this.fullScreenButton,
    settingButton: settingButton ?? this.settingButton,
    lighthouseSetting: lighthouseSetting ?? this.lighthouseSetting,
    adsSettings: adsSettings ?? this.adsSettings,
    secureSurface: secureSurface ?? this.secureSurface,
    subtitleSize: subtitleSize ?? this.subtitleSize,
    subtitleBackgroundEnabled:
        subtitleBackgroundEnabled ?? this.subtitleBackgroundEnabled,
    subtitlePaddingBottomPercentage: subtitlePaddingBottomPercentage ??
        this.subtitlePaddingBottomPercentage,
  );
}