Skip to content

Commit

Permalink
Version 0.14.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanheise committed Aug 26, 2020
1 parent 0d6f693 commit a6172d7
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 23 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
## 0.14.0

* audio session management now handled by audio_session (see [Migration Guide](https://github.com/ryanheise/audio_service/wiki/Migration-Guide#0140)).
* Exceptions in background audio task are logged and forwarded to client.

## 0.13.0

* All BackgroundAudioTask callbacks are now async.
Expand Down
24 changes: 2 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ You can implement these callbacks to play any sort of audio that is appropriate
| ------- | :-------: | :-----: |
| background audio |||
| headset clicks |||
| Handle phonecall interruptions |||
| start/stop/play/pause/seek/rate |||
| fast forward/rewind |||
| repeat/shuffle mode |||
Expand All @@ -34,21 +33,9 @@ You can implement these callbacks to play any sort of audio that is appropriate

If you'd like to help with any missing features, please join us on the [GitHub issues page](https://github.com/ryanheise/audio_service/issues).

## Migrating to 0.13.0
## Migrating to 0.14.0

As of 0.13.0, all callbacks in `AudioBackgroundTask` are asynchronous. This allows the main isolate to await their completion and better synchronise with the background audio task.

As of 0.11.0, the background audio task terminates when `onStop` completes rather than when `onStart` completes.

As of 0.10.0, your broadcast receiver in `AndroidManifest.xml` should be replaced with the one below to ensure that headset and notification clicks continue to work:

```xml
<receiver android:name="com.ryanheise.audioservice.MediaButtonReceiver" >
<intent-filter>
<action android:name="android.intent.action.MEDIA_BUTTON" />
</intent-filter>
</receiver>
```
Audio focus, interruptions (e.g. phone calls), mixing, ducking and the configuration of your app's audio category and attributes, are now handled by the [audio_session](https://pub.dev/packages/audio_session) package. Read the [Migration Guide](https://github.com/ryanheise/audio_service/wiki/Migration-Guide#0140) for details.

## Can I make use of other plugins within the background audio task?

Expand Down Expand Up @@ -80,13 +67,6 @@ class MyBackgroundTask extends BackgroundAudioTask {
onSkipToPrevious() {}
// Handle a request to seek to a position.
onSeekTo(Duration position) {}
// Handle a phone call or other interruption.
onAudioFocusLost(AudioInterruption interruption) {}
// Handle the end of an audio interruption.
onAudioFocusGained(AudioInterruption interruption) {}
// Handle when the user unplugs the headphones.
onAudioBecomingNoisy(AudioInterruption interruption) {}
// See the API documentation for more.
}
```

Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: audio_service
description: Flutter plugin to play audio in the background while the screen is off.
version: 0.13.0
version: 0.14.0
homepage: https://github.com/ryanheise/audio_service

environment:
Expand Down

0 comments on commit a6172d7

Please sign in to comment.