updateCurrentAudioPlayInfo method
dynamic
updateCurrentAudioPlayInfo({})
function for updating currently played audio information
progress
(required) progress of currently played audio
isCompleted
(required) whether currently played audio is finished
isPaused
(optional) whether currently played audio is paused
Implementation
updateCurrentAudioPlayInfo({
required double progress,
required bool isCompleted,
bool? isPaused,
}) {
if (_audioPlayInfo != null) {
_currentPlayAudioInfo = CurrentPlayAudioInfo(
progress: progress,
playInfo: _audioPlayInfo!,
isCompleted: isCompleted,
isPaused: isPaused ?? false,
);
notifyListener(TencentCloudChatMessageDataKeys.currentPlayAudioInfo as T);
}
}