Skip to content

Commit 67de9c8

Browse files
committed
refactor(player-with-controls): replace provider call to context.read
re-sync with master revert formatted line for LayoutBuilder
1 parent c59e4fa commit 67de9c8

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/src/player_with_controls.dart

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ class PlayerWithControls extends StatelessWidget {
3333
ChewieController chewieController,
3434
BuildContext context,
3535
) {
36-
final playerNotifier = Provider.of<PlayerNotifier>(context, listen: false);
36+
final playerNotifier = context.read<PlayerNotifier>();
3737
final child = Stack(
3838
children: [
3939
if (chewieController.placeholder != null) chewieController.placeholder!,
@@ -93,7 +93,8 @@ class PlayerWithControls extends StatelessWidget {
9393
return child;
9494
}
9595

96-
return LayoutBuilder(builder: (BuildContext context, BoxConstraints constraints) {
96+
return LayoutBuilder(
97+
builder: (BuildContext context, BoxConstraints constraints) {
9798
return Center(
9899
child: SizedBox(
99100
height: constraints.maxHeight,

0 commit comments

Comments
 (0)