[video_player] update dependencies plugin version (#43)
Updates - Upgrade `video_player_platform_interface` from 4.1.0 to 4.2.0 - Update example - `video_player` from 2.1.12 to 2.2.5 - Refactor source file
This commit is contained in:
@@ -33,7 +33,7 @@ class _App extends StatelessWidget {
|
||||
tabs: <Widget>[
|
||||
Tab(
|
||||
icon: Icon(Icons.cloud),
|
||||
text: "Remote",
|
||||
text: 'Remote',
|
||||
),
|
||||
],
|
||||
),
|
||||
@@ -109,7 +109,7 @@ class _ControlsOverlay extends StatelessWidget {
|
||||
const _ControlsOverlay({Key? key, required this.controller})
|
||||
: super(key: key);
|
||||
|
||||
static const _examplePlaybackRates = [
|
||||
static const List<double> _examplePlaybackRates = [
|
||||
0.25,
|
||||
0.5,
|
||||
1.0,
|
||||
@@ -127,13 +127,13 @@ class _ControlsOverlay extends StatelessWidget {
|
||||
return Stack(
|
||||
children: <Widget>[
|
||||
AnimatedSwitcher(
|
||||
duration: Duration(milliseconds: 50),
|
||||
reverseDuration: Duration(milliseconds: 200),
|
||||
duration: const Duration(milliseconds: 50),
|
||||
reverseDuration: const Duration(milliseconds: 200),
|
||||
child: controller.value.isPlaying
|
||||
? SizedBox.shrink()
|
||||
? const SizedBox.shrink()
|
||||
: Container(
|
||||
color: Colors.black26,
|
||||
child: Center(
|
||||
child: const Center(
|
||||
child: Icon(
|
||||
Icons.play_arrow,
|
||||
color: Colors.white,
|
||||
@@ -157,7 +157,7 @@ class _ControlsOverlay extends StatelessWidget {
|
||||
},
|
||||
itemBuilder: (context) {
|
||||
return [
|
||||
for (final speed in _examplePlaybackRates)
|
||||
for (final double speed in _examplePlaybackRates)
|
||||
PopupMenuItem(
|
||||
value: speed,
|
||||
child: Text('${speed}x'),
|
||||
|
||||
@@ -3,13 +3,13 @@ description: Demonstrates how to use the video_player plugin.
|
||||
publish_to: none
|
||||
|
||||
environment:
|
||||
sdk: ">=2.12.0 <3.0.0"
|
||||
flutter: ">=2.0.0"
|
||||
sdk: ">=2.14.0 <3.0.0"
|
||||
flutter: ">=2.5.0"
|
||||
|
||||
dependencies:
|
||||
flutter:
|
||||
sdk: flutter
|
||||
video_player: ^2.1.12
|
||||
video_player: ^2.2.5
|
||||
video_player_elinux:
|
||||
path: ../
|
||||
|
||||
|
||||
Reference in New Issue
Block a user