Skip to content

Commit f5d99ea

Browse files
authored
Merge pull request #900 from diegotori/flutter_3.29_upgrade
Flutter 3.29 upgrade.
2 parents 6806424 + d172b64 commit f5d99ea

File tree

6 files changed

+29
-38
lines changed

6 files changed

+29
-38
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
# refer to https://docs.flutter.dev/development/tools/sdk/releases.
3232
# Note: The version below should be manually updated to the latest second most recent version
3333
# after a new stable version comes out.
34-
- "3.24.5"
34+
- "3.27.4"
3535
- "3.x"
3636
steps:
3737
- name: 📚 Git Checkout

example/lib/app/app.dart

Lines changed: 15 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,7 @@ import 'package:flutter/material.dart';
66
import 'package:video_player/video_player.dart';
77

88
class ChewieDemo extends StatefulWidget {
9-
const ChewieDemo({
10-
super.key,
11-
this.title = 'Chewie Demo',
12-
});
9+
const ChewieDemo({super.key, this.title = 'Chewie Demo'});
1310

1411
final String title;
1512

@@ -47,13 +44,15 @@ class _ChewieDemoState extends State<ChewieDemo> {
4744
];
4845

4946
Future<void> initializePlayer() async {
50-
_videoPlayerController1 =
51-
VideoPlayerController.networkUrl(Uri.parse(srcs[currPlayIndex]));
52-
_videoPlayerController2 =
53-
VideoPlayerController.networkUrl(Uri.parse(srcs[currPlayIndex]));
47+
_videoPlayerController1 = VideoPlayerController.networkUrl(
48+
Uri.parse(srcs[currPlayIndex]),
49+
);
50+
_videoPlayerController2 = VideoPlayerController.networkUrl(
51+
Uri.parse(srcs[currPlayIndex]),
52+
);
5453
await Future.wait([
5554
_videoPlayerController1.initialize(),
56-
_videoPlayerController2.initialize()
55+
_videoPlayerController2.initialize(),
5756
]);
5857
_createChewieController();
5958
setState(() {});
@@ -93,7 +92,7 @@ class _ChewieDemoState extends State<ChewieDemo> {
9392
TextSpan(
9493
text: 'subtitles',
9594
style: TextStyle(color: Colors.blue, fontSize: 18),
96-
)
95+
),
9796
],
9897
),
9998
),
@@ -130,9 +129,7 @@ class _ChewieDemoState extends State<ChewieDemo> {
130129
subtitleBuilder: (context, dynamic subtitle) => Container(
131130
padding: const EdgeInsets.all(10.0),
132131
child: subtitle is InlineSpan
133-
? RichText(
134-
text: subtitle,
135-
)
132+
? RichText(text: subtitle)
136133
: Text(
137134
subtitle.toString(),
138135
style: const TextStyle(color: Colors.black),
@@ -176,19 +173,15 @@ class _ChewieDemoState extends State<ChewieDemo> {
176173
platform: _platform ?? Theme.of(context).platform,
177174
),
178175
home: Scaffold(
179-
appBar: AppBar(
180-
title: Text(widget.title),
181-
),
176+
appBar: AppBar(title: Text(widget.title)),
182177
body: Column(
183178
children: <Widget>[
184179
Expanded(
185180
child: Center(
186181
child: _chewieController != null &&
187182
_chewieController!
188183
.videoPlayerController.value.isInitialized
189-
? Chewie(
190-
controller: _chewieController!,
191-
)
184+
? Chewie(controller: _chewieController!)
192185
: const Column(
193186
mainAxisAlignment: MainAxisAlignment.center,
194187
children: [
@@ -261,7 +254,7 @@ class _ChewieDemoState extends State<ChewieDemo> {
261254
child: Text("Portrait Video"),
262255
),
263256
),
264-
)
257+
),
265258
],
266259
),
267260
Row(
@@ -291,7 +284,7 @@ class _ChewieDemoState extends State<ChewieDemo> {
291284
child: Text("iOS controls"),
292285
),
293286
),
294-
)
287+
),
295288
],
296289
),
297290
Row(
@@ -324,7 +317,7 @@ class _ChewieDemoState extends State<ChewieDemo> {
324317
}
325318
},
326319
),
327-
)
320+
),
328321
],
329322
),
330323
),

example/lib/main.dart

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,5 @@ import 'package:chewie_example/app/app.dart';
22
import 'package:flutter/material.dart';
33

44
void main() {
5-
runApp(
6-
const ChewieDemo(),
7-
);
5+
runApp(const ChewieDemo());
86
}

example/pubspec.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,20 @@ version: 1.0.0
44
publish_to: none
55

66
environment:
7-
sdk: '>=3.3.0 <4.0.0'
8-
flutter: ">=3.19.0"
7+
sdk: '>=3.6.0 <4.0.0'
8+
flutter: ">=3.27.0"
99

1010
dependencies:
1111
chewie:
1212
path: ../
1313
flutter:
1414
sdk: flutter
15+
video_player: ^2.9.3
1516

16-
video_player: ^2.9.1
1717
dev_dependencies:
1818
flutter_test:
1919
sdk: flutter
20-
flutter_lints: ^4.0.0
20+
flutter_lints: ^5.0.0
2121

2222
# For information on the generic Dart part of this file, see the
2323
# following page: https://www.dartlang.org/tools/pub/pubspec

lib/chewie.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
library chewie;
1+
library;
22

33
export 'src/chewie_player.dart';
44
export 'src/chewie_progress_colors.dart';
55
export 'src/cupertino/cupertino_controls.dart';
66
export 'src/material/material_controls.dart';
7-
export 'src/material/material_progress_bar.dart';
87
export 'src/material/material_desktop_controls.dart';
8+
export 'src/material/material_progress_bar.dart';
99
export 'src/models/index.dart';

pubspec.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,21 @@ version: 1.10.0
44
homepage: https://github.com/fluttercommunity/chewie
55

66
environment:
7-
sdk: '>=3.5.0 <4.0.0'
8-
flutter: ">=3.24.0"
7+
sdk: '>=3.6.0 <4.0.0'
8+
flutter: ">=3.27.0"
99

1010
dependencies:
11-
cupertino_icons: ^1.0.5
11+
cupertino_icons: ^1.0.8
1212
flutter:
1313
sdk: flutter
1414
provider: ^6.1.2
15-
video_player: ^2.9.1
16-
wakelock_plus: ^1.2.8
15+
video_player: ^2.9.3
16+
wakelock_plus: ^1.2.10
1717

1818
dev_dependencies:
1919
flutter_test:
2020
sdk: flutter
21-
flutter_lints: ^4.0.0
21+
flutter_lints: ^5.0.0
2222

2323
flutter:
2424
uses-material-design: true

0 commit comments

Comments
 (0)