File tree 3 files changed +7
-8
lines changed
packages/video_player/video_player
android/src/main/java/io/flutter/plugins/videoplayer 3 files changed +7
-8
lines changed Original file line number Diff line number Diff line change
1
+ ## 2.0.1
2
+
3
+ * Remove the deprecated API "exoPlayer.setAudioAttributes".
4
+
1
5
## 2.0.0
2
6
3
7
* Migrate to null safety.
Original file line number Diff line number Diff line change 5
5
6
6
import android .content .Context ;
7
7
import android .net .Uri ;
8
- import android .os .Build ;
9
8
import android .view .Surface ;
10
9
import com .google .android .exoplayer2 .C ;
11
10
import com .google .android .exoplayer2 .ExoPlaybackException ;
@@ -222,12 +221,8 @@ void sendBufferingUpdate() {
222
221
223
222
@ SuppressWarnings ("deprecation" )
224
223
private static void setAudioAttributes (SimpleExoPlayer exoPlayer , boolean isMixMode ) {
225
- if (Build .VERSION .SDK_INT >= Build .VERSION_CODES .LOLLIPOP ) {
226
- exoPlayer .setAudioAttributes (
227
- new AudioAttributes .Builder ().setContentType (C .CONTENT_TYPE_MOVIE ).build (), !isMixMode );
228
- } else {
229
- exoPlayer .setAudioStreamType (C .STREAM_TYPE_MUSIC );
230
- }
224
+ exoPlayer .setAudioAttributes (
225
+ new AudioAttributes .Builder ().setContentType (C .CONTENT_TYPE_MOVIE ).build (), !isMixMode );
231
226
}
232
227
233
228
void play () {
Original file line number Diff line number Diff line change 1
1
name : video_player
2
2
description : Flutter plugin for displaying inline video with other Flutter
3
3
widgets on Android, iOS, and web.
4
- version : 2.0.0
4
+ version : 2.0.1
5
5
homepage : https://github.com/flutter/plugins/tree/master/packages/video_player/video_player
6
6
7
7
flutter :
You can’t perform that action at this time.
0 commit comments