fix pop, fix gradient background looking bad

This commit is contained in:
Pato05 2024-04-29 16:51:04 +02:00
parent f9389ef50d
commit 50717ebbd3
No known key found for this signature in database
GPG key ID: F53CA394104BA0CB
2 changed files with 3 additions and 2 deletions

View file

@ -74,7 +74,7 @@ class FancyScaffoldState extends State<FancyScaffold>
return ValueListenableBuilder( return ValueListenableBuilder(
valueListenable: statusNotifier, valueListenable: statusNotifier,
builder: (context, state, child) => PopScope( builder: (context, state, child) => PopScope(
canPop: state != AnimationStatus.dismissed, canPop: state == AnimationStatus.dismissed,
onPopInvoked: state == AnimationStatus.dismissed onPopInvoked: state == AnimationStatus.dismissed
? null ? null
: (_) => dragController.fling(velocity: -1.0), : (_) => dragController.fling(velocity: -1.0),

View file

@ -195,7 +195,8 @@ class PlayerScreenBackground extends StatelessWidget {
end: Alignment.bottomCenter, end: Alignment.bottomCenter,
colors: [ colors: [
if (provider.dominantColor != null) if (provider.dominantColor != null)
provider.dominantColor!, Color.lerp(provider.dominantColor,
isLightMode ? Colors.white : Colors.black, 0.5)!,
Theme.of(context).scaffoldBackgroundColor, Theme.of(context).scaffoldBackgroundColor,
], ],
stops: const [0.0, 0.6], stops: const [0.0, 0.6],