copyWith method
创建一个新的配置,覆盖当前配置的某些属性
Implementation
RCKVoiceStyleConfig copyWith({
double? iconSize,
Color? playingColor,
Color? notPlayingColor,
String? customPlayingIconPath,
String? customNotPlayingIconPath,
TextStyle? durationTextStyle,
}) {
return RCKVoiceStyleConfig(
iconSize: iconSize ?? this.iconSize,
playingColor: playingColor ?? this.playingColor,
notPlayingColor: notPlayingColor ?? this.notPlayingColor,
customPlayingIconPath:
customPlayingIconPath ?? this.customPlayingIconPath,
customNotPlayingIconPath:
customNotPlayingIconPath ?? this.customNotPlayingIconPath,
durationTextStyle: durationTextStyle ?? this.durationTextStyle,
);
}