Skip to content
This repository has been archived by the owner on Jan 10, 2024. It is now read-only.

Commit

Permalink
Set minimum Flutter 3 for web.
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanheise committed May 15, 2023
1 parent 6692354 commit 3f61f23
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 16 deletions.
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.4.8

* Update minimum flutter version to 3.0.

## 0.4.7

* Fix bug handling simultaneous play requests.
Expand Down
7 changes: 4 additions & 3 deletions just_audio_web/analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
include: package:flutter_lints/flutter.yaml

analyzer:
strong-mode:
implicit-casts: false
implicit-dynamic: false
language:
strict-casts: true
strict-inference: true
strict-raw-types: true

linter:
rules:
Expand Down
18 changes: 9 additions & 9 deletions just_audio_web/lib/just_audio_web.dart
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ abstract class JustAudioPlayer extends AudioPlayerPlatform {
class Html5AudioPlayer extends JustAudioPlayer {
final _audioElement = AudioElement();
late final _playPauseQueue = _PlayPauseQueue(_audioElement);
Completer? _durationCompleter;
Completer<dynamic>? _durationCompleter;
AudioSourcePlayer? _audioSourcePlayer;
LoopModeMessage _loopMode = LoopModeMessage.off;
bool _shuffleModeEnabled = false;
Expand Down Expand Up @@ -585,10 +585,10 @@ abstract class UriAudioSourcePlayer extends IndexedAudioSourcePlayer {
final Uri uri;

/// The headers to include in the request (unsupported).
final Map? headers;
final Map<String, String>? headers;
double? _resumePos;
Duration? _duration;
Completer? _completer;
Completer<dynamic>? _completer;
int? _initialPos;

UriAudioSourcePlayer(
Expand Down Expand Up @@ -679,22 +679,22 @@ abstract class UriAudioSourcePlayer extends IndexedAudioSourcePlayer {

/// A player for a [ProgressiveAudioSourceMessage].
class ProgressiveAudioSourcePlayer extends UriAudioSourcePlayer {
ProgressiveAudioSourcePlayer(
Html5AudioPlayer html5AudioPlayer, String id, Uri uri, Map? headers)
ProgressiveAudioSourcePlayer(Html5AudioPlayer html5AudioPlayer, String id,
Uri uri, Map<String, String>? headers)
: super(html5AudioPlayer, id, uri, headers);
}

/// A player for a [DashAudioSourceMessage].
class DashAudioSourcePlayer extends UriAudioSourcePlayer {
DashAudioSourcePlayer(
Html5AudioPlayer html5AudioPlayer, String id, Uri uri, Map? headers)
DashAudioSourcePlayer(Html5AudioPlayer html5AudioPlayer, String id, Uri uri,
Map<String, String>? headers)
: super(html5AudioPlayer, id, uri, headers);
}

/// A player for a [HlsAudioSourceMessage].
class HlsAudioSourcePlayer extends UriAudioSourcePlayer {
HlsAudioSourcePlayer(
Html5AudioPlayer html5AudioPlayer, String id, Uri uri, Map? headers)
HlsAudioSourcePlayer(Html5AudioPlayer html5AudioPlayer, String id, Uri uri,
Map<String, String>? headers)
: super(html5AudioPlayer, id, uri, headers);
}

Expand Down
8 changes: 4 additions & 4 deletions 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.4.7
version: 0.4.8

flutter:
plugin:
Expand All @@ -11,7 +11,7 @@ flutter:
fileName: just_audio_web.dart

dependencies:
just_audio_platform_interface: ^4.2.0
just_audio_platform_interface: ^4.2.1
# just_audio_platform_interface:
# path: ../just_audio_platform_interface
flutter:
Expand All @@ -23,5 +23,5 @@ dev_dependencies:
flutter_lints: ^2.0.1

environment:
sdk: ">=2.12.0 <3.0.0"
flutter: ">=1.12.13+hotfix.5"
sdk: ">=2.14.0 <4.0.0"
flutter: ">=3.0.0"

0 comments on commit 3f61f23

Please sign in to comment.