edits
This commit is contained in:
parent
b6639fb1c9
commit
0a7af1d813
10 changed files with 743 additions and 35 deletions
|
|
@ -4,6 +4,7 @@ import 'package:flutter/foundation.dart' show kIsWeb;
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
import 'package:just_audio_background/just_audio_background.dart';
|
||||
import 'package:just_audio_media_kit/just_audio_media_kit.dart';
|
||||
|
||||
import 'settings/settings_store.dart';
|
||||
import 'shell/app_shell.dart';
|
||||
|
|
@ -15,6 +16,13 @@ import 'widgets/splash_screen.dart';
|
|||
|
||||
Future<void> main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
// Desktop (Linux/Windows) has no native just_audio backend; route playback
|
||||
// through libmpv via media_kit. Audio then lands on the system mixer
|
||||
// (PipeWire/PulseAudio), where a system EQ (e.g. EasyEffects) can shape it.
|
||||
// macOS/iOS/Android keep just_audio's own native backends.
|
||||
if (!kIsWeb && (Platform.isLinux || Platform.isWindows)) {
|
||||
JustAudioMediaKit.ensureInitialized(linux: true, windows: true);
|
||||
}
|
||||
// Lock-screen / notification transport is only available where audio_service
|
||||
// has a backend — Android/iOS. Skipping init elsewhere keeps the Linux dev
|
||||
// target (and tests) running.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue