mirror of
https://github.com/KRTirtho/spotube.git
synced 2026-05-08 16:24:36 +00:00
fix(mobile): player overlay should not be visible when the player is not playing
This commit is contained in:
parent
bc5d66d057
commit
41b59b7086
@ -24,11 +24,10 @@ class PlayerOverlay extends HookConsumerWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context, ref) {
|
||||
final canShow = ref.watch(
|
||||
ProxyPlaylistNotifier.provider.select((s) => s.active != null),
|
||||
);
|
||||
final playlistNotifier = ref.watch(ProxyPlaylistNotifier.notifier);
|
||||
final playlist = ref.watch(ProxyPlaylistNotifier.provider);
|
||||
final canShow = playlist.activeTrack != null;
|
||||
|
||||
final playing =
|
||||
useStream(audioPlayer.playingStream).data ?? audioPlayer.isPlaying;
|
||||
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_hooks/flutter_hooks.dart';
|
||||
import 'package:spotube/models/logger.dart';
|
||||
|
||||
void useCustomStatusBarColor(
|
||||
Color color,
|
||||
@ -48,9 +47,6 @@ void useCustomStatusBarColor(
|
||||
if (automaticSystemUiAdjustment != null) {
|
||||
// ignore: deprecated_member_use
|
||||
WidgetsBinding.instance.renderView.automaticSystemUiAdjustment = false;
|
||||
getLogger(["useCustomStatusBarColor"]).w(
|
||||
"renderView.automaticSystemUiAdjustment is deprecated. Please use SystemChrome.setSystemUIOverlayStyle instead.",
|
||||
);
|
||||
}
|
||||
};
|
||||
}, [color, isCurrentRoute, statusBarColor]);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user