copyWith method

YoutubePlayerFlags copyWith({
  1. bool? hideControls,
  2. bool? autoPlay,
  3. bool? mute,
  4. bool? showVideoProgressIndicator,
  5. bool? isLive,
  6. bool? hideThumbnail,
  7. bool? disableDragSeek,
  8. bool? loop,
  9. bool? enableCaption,
  10. bool? forceHD,
  11. String? captionLanguage,
  12. int? startAt,
  13. int? endAt,
  14. bool? controlsVisibleAtStart,
  15. bool? useHybridComposition,
  16. bool? showLiveFullscreenButton,
})

Copies new values assigned to the YoutubePlayerFlags.

Implementation

YoutubePlayerFlags copyWith({
  bool? hideControls,
  bool? autoPlay,
  bool? mute,
  bool? showVideoProgressIndicator,
  bool? isLive,
  bool? hideThumbnail,
  bool? disableDragSeek,
  bool? loop,
  bool? enableCaption,
  bool? forceHD,
  String? captionLanguage,
  int? startAt,
  int? endAt,
  bool? controlsVisibleAtStart,
  bool? useHybridComposition,
  bool? showLiveFullscreenButton,
}) {
  return YoutubePlayerFlags(
    autoPlay: autoPlay ?? this.autoPlay,
    captionLanguage: captionLanguage ?? this.captionLanguage,
    disableDragSeek: disableDragSeek ?? this.disableDragSeek,
    enableCaption: enableCaption ?? this.enableCaption,
    hideControls: hideControls ?? this.hideControls,
    hideThumbnail: hideThumbnail ?? this.hideThumbnail,
    isLive: isLive ?? this.isLive,
    loop: loop ?? this.loop,
    mute: mute ?? this.mute,
    forceHD: forceHD ?? this.forceHD,
    startAt: startAt ?? this.startAt,
    endAt: endAt ?? this.endAt,
    controlsVisibleAtStart:
        controlsVisibleAtStart ?? this.controlsVisibleAtStart,
    useHybridComposition: useHybridComposition ?? this.useHybridComposition,
    showLiveFullscreenButton:
        showLiveFullscreenButton ?? this.showLiveFullscreenButton,
  );
}