mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-05-27 11:38:40 +00:00
mod: exit
This commit is contained in:
@@ -1,3 +1,5 @@
|
|||||||
|
import 'dart:io';
|
||||||
|
|
||||||
import 'package:audio_service/audio_service.dart';
|
import 'package:audio_service/audio_service.dart';
|
||||||
import 'package:flutter/cupertino.dart';
|
import 'package:flutter/cupertino.dart';
|
||||||
import 'package:hive/hive.dart';
|
import 'package:hive/hive.dart';
|
||||||
@@ -58,6 +60,13 @@ class VideoPlayerServiceHandler extends BaseAudioHandler with SeekHandler {
|
|||||||
// await player.seekTo(position);
|
// await player.seekTo(position);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@override
|
||||||
|
Future<void> onTaskRemoved() async {
|
||||||
|
if (Platform.isAndroid) {
|
||||||
|
exit(0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Future<void> setMediaItem(MediaItem newMediaItem) async {
|
Future<void> setMediaItem(MediaItem newMediaItem) async {
|
||||||
if (!enableBackgroundPlay) return;
|
if (!enableBackgroundPlay) return;
|
||||||
// print("此时调用栈为:");
|
// print("此时调用栈为:");
|
||||||
|
|||||||
Reference in New Issue
Block a user