Skip to content

Commit

Permalink
just_audio_web 0.3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanheise committed Mar 22, 2021
1 parent 09dafe4 commit de26fc5
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 7 deletions.
4 changes: 4 additions & 0 deletions just_audio/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## Next release

* Propagate play() exceptions on web (@twogood).

## 0.7.1

* Fix IllegalSeekPositionException on Android (@DenisShakinov).
Expand Down
8 changes: 3 additions & 5 deletions just_audio/lib/just_audio.dart
Original file line number Diff line number Diff line change
Expand Up @@ -808,13 +808,11 @@ class AudioPlayer {

Future<void> _sendPlayRequest(
AudioPlayerPlatform platform, Completer<void>? playCompleter) async {
try
{
try {
await platform.play(PlayRequest());
playCompleter?.complete();
}
catch (e) {
playCompleter?.completeError(e);
} catch (e, stackTrace) {
playCompleter?.completeError(e, stackTrace);
}
}

Expand Down
4 changes: 4 additions & 0 deletions just_audio_web/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.3.1

* Propagate play() exceptions (@twogood).

## 0.3.0

* Null safety.
Expand Down
2 changes: 1 addition & 1 deletion just_audio_web/lib/just_audio_web.dart
Original file line number Diff line number Diff line change
Expand Up @@ -749,7 +749,7 @@ class ClippingAudioSourcePlayer extends IndexedAudioSourcePlayer {
Future<void> play() async {
_interruptPlay(ClipInterruptReason.simultaneous);
_audioElement.currentTime = _resumePos!;
_audioElement.play();
await _audioElement.play();
_completer = Completer<ClipInterruptReason>();
ClipInterruptReason reason;
while ((reason = await _completer!.future) == ClipInterruptReason.seek) {
Expand Down
2 changes: 1 addition & 1 deletion just_audio_web/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: just_audio_web
description: Web platform implementation of just_audio. This implementation is endorsed and therefore doesn't require a direct dependency.
homepage: https://github.com/ryanheise/just_audio/tree/master/just_audio_web
version: 0.3.0
version: 0.3.1

flutter:
plugin:
Expand Down

0 comments on commit de26fc5

Please sign in to comment.