From 5a0540924d6f951857f3837ae0b51a0da9dba49e Mon Sep 17 00:00:00 2001 From: Spark <2666652@gmail.com> Date: Sun, 10 Nov 2024 19:02:58 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=9E=E7=8E=B0=E9=9F=B3=E4=B9=90=E4=B8=8B?= =?UTF-8?q?=E8=BD=BD=E5=8A=9F=E8=83=BD=EF=BC=8C=E6=9B=BF=E6=8D=A2=E6=92=AD?= =?UTF-8?q?=E6=94=BE=E5=99=A8=E4=B8=BA=E6=B5=81=E5=BC=8F=E6=92=AD=E6=94=BE?= =?UTF-8?q?=E5=99=A8=EF=BC=8C=E4=BF=AE=E5=A4=8D=E4=B8=8A\=E4=B8=8B?= =?UTF-8?q?=E4=B8=80=E6=9B=B2BUG=EF=BC=8C=E4=BF=AE=E5=A4=8D=E6=92=AD?= =?UTF-8?q?=E6=94=BE\=E6=9A=82=E5=81=9C=E6=8C=89=E9=92=AE=E7=82=B9?= =?UTF-8?q?=E5=87=BBBUG=EF=BC=8C=E5=BC=95=E5=85=A5=E6=AD=8C=E6=9B=B2?= =?UTF-8?q?=E5=88=87=E6=8D=A2=E5=8A=A0=E8=BD=BD=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- android/app/src/main/AndroidManifest.xml | 4 + assets/img/music_download_completed.png | Bin 0 -> 589 bytes lib/api/api_download.dart | 126 +++++ lib/view/home_view.dart | 2 +- lib/view/music_view.dart | 407 ++++++++++++---- macos/Flutter/GeneratedPluginRegistrant.swift | 4 + pubspec.lock | 444 ++++++++++++------ pubspec.yaml | 3 +- windows/flutter/CMakeLists.txt | 7 +- .../flutter/generated_plugin_registrant.cc | 3 + windows/flutter/generated_plugins.cmake | 1 + 11 files changed, 741 insertions(+), 260 deletions(-) create mode 100644 assets/img/music_download_completed.png create mode 100644 lib/api/api_download.dart diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index 54c6148..b5d3616 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -30,4 +30,8 @@ android:name="flutterEmbedding" android:value="2" /> + + + + diff --git a/assets/img/music_download_completed.png b/assets/img/music_download_completed.png new file mode 100644 index 0000000000000000000000000000000000000000..6d524f1eb8d2a485f3adca3a2f5aae40c16c86e3 GIT binary patch literal 589 zcmV-T0Px%2T4RhR9Hvtm(fwfFbsy(Nhp(`P6C|-I0k8%1a}Ya2$MiRBjp@pJ5H{T@f{Bw zSo-`+`t9sw#Zpxjkw+1E4IvCGLX2B>Yc{LuNkpCu;AKq=-?J9rLqt#k1vY?9flYx; zf!ives(TUHhpWTX98OicjL2e1%dY=9p{o8^;;PH_03>!jgb?m)hbaLd>2nKW4j@TR zn5JEq04M<$O%w1fLl03#U%Z_7Ii^5e50U~z8kD9@lc!Tu>OUaf{UOr@ zP$@?m+)vIc36o-xh!H%yxn0%bDd)f_aqb3aK#ZfNs$Z4>BR$NN6TrjH=oFfs$7NQI zG`UM(bv{+4Cq6~w&3gy{r#`g&e-18xDO)l^4hD_dE zTQZWfyfow;0GO3-F1hu`cn~`!zk9=Zh^Vru1E6>hKtGOBPr^cj`Nv9ZK$G1eeE#DV zpOouw3Q{7IjeorKg4n3hVDVJQY$rtlq>sH|xzbTRj$>#LxK}P)4~Hjo6((lm0qmR7 zy&x(z@c|!6v)Uyf7o07VoxCUs3|;T`?Is2Eu*isdq-fZ-Z=aad%>fd*z5bk>g$fwg b _requestStoragePermission(BuildContext context) async { + // 检查权限状态 + PermissionStatus status = await Permission.manageExternalStorage.status; + + if (status.isDenied) { + // 如果权限被拒绝,请求权限 + // PermissionStatus status1 = await Permission.storage.request(); + status = await Permission.manageExternalStorage.request(); + print(status); + if (status.isDenied || status.isPermanentlyDenied || status.isRestricted) { + if (context.mounted) { + showDialog( + context: context, + builder: (BuildContext context) => AlertDialog( + title: const Text('需要存储权限'), + content: const Text('下载音乐需要存储权限,请在设置中允许访问存储权限。'), + actions: [ + TextButton( + child: const Text('取消'), + onPressed: () => Navigator.of(context).pop(), + ), + TextButton( + child: const Text('去设置'), + onPressed: () { + Navigator.of(context).pop(); + openAppSettings(); // 打开应用设置页面 + }, + ), + ], + ), + ); + } + return false; + } + } + return status.isGranted; + } + + Future downloadMusic({ + required String musicUrl, + required String name, + required BuildContext context, + required Function(double) onProgress, + }) async { + try { + // 音频文件后缀列表 + final List audioExtensions = [ + '.mp3', + '.wav', + '.m4a', + '.aac', + '.ogg', + '.flac', + '.wma', + '.amr' + ]; + + // 检查URL中是否包含音频后缀 + String fileExtension = ''; + + final Uri uri = Uri.parse(musicUrl); + final String pathOnly = uri.path.toLowerCase(); + + for (var ext in audioExtensions) { + if (pathOnly.contains(ext)) { + fileExtension = ext; + break; + } + } + + // 如果找到后缀,添加到文件名 + final fileName = fileExtension.isNotEmpty + ? name.endsWith(fileExtension) ? name : name + fileExtension + : name; + + // 检查并申请权限 + if (!await _requestStoragePermission(context)) { + throw Exception('没有存储权限'); + } + + // 获取下载目录 + final downloadDir = Directory('/storage/emulated/0/MTMusic'); + if (!await downloadDir.exists()) { + await downloadDir.create(recursive: true); + } + + // 构建完整的文件路径 + final filePath = '${downloadDir.path}/$fileName'; + + print("Music URL: $musicUrl"); + print("Saving as: $filePath"); + + // 开始下载 + await dio.download( + musicUrl, + filePath, + options: Options( + headers: { + // 如果需要添加请求头可以在这里添加 + }, + ), + onReceiveProgress: (received, total) { + if (total != -1) { + // 计算下载进度并通过回调函数传递 + double progress = received / total; + onProgress(progress); // 调用回调函数 + } + }, + ); + + return filePath; + } catch (e) { + print('Download error: $e'); + return null; + } + } +} \ No newline at end of file diff --git a/lib/view/home_view.dart b/lib/view/home_view.dart index 931365c..a64f87a 100644 --- a/lib/view/home_view.dart +++ b/lib/view/home_view.dart @@ -284,7 +284,7 @@ class _HomeViewState extends State { context, MaterialPageRoute( builder: (context) => MusicView( - song: songs[index], + songList: songs, initialSongIndex: index, ), ), diff --git a/lib/view/music_view.dart b/lib/view/music_view.dart index fdceb16..b527d1c 100644 --- a/lib/view/music_view.dart +++ b/lib/view/music_view.dart @@ -1,21 +1,25 @@ - +import 'dart:async'; +import 'dart:io'; +import 'package:path/path.dart' as path; import 'package:flutter/material.dart'; import 'package:get/get.dart'; +import 'package:just_audio/just_audio.dart'; import 'package:music_player_miao/common_widget/app_data.dart'; import 'package:music_player_miao/models/universal_bean.dart'; import '../../view_model/home_view_model.dart'; -import 'package:audioplayers/audioplayers.dart'; - +import '../api/api_download.dart'; import '../api/api_music_likes.dart'; -import '../api/api_music_list.dart'; import '../common_widget/Song_widegt.dart'; -import '../models/getMusicList_bean.dart'; class MusicView extends StatefulWidget { - final Song song; + final List songList; final int initialSongIndex; - const MusicView({super.key, required this.song, required this.initialSongIndex}); + const MusicView({ + super.key, + required this.songList, + required this.initialSongIndex + }); @override State createState() => _MusicViewState(); @@ -26,127 +30,296 @@ class _MusicViewState extends State { bool _isDisposed = false; AppData appData = AppData(); late int currentSongIndex; + late AudioPlayer _audioPlayer; - List song2 = []; - List artist = []; - List music = []; - List likes = []; - List collection = []; + double _downloadProgress = 0.0; + bool _isDownloading = false; + bool _isDownloaded = false; - Future _fetchSonglistData() async { - MusicListBean bean1 = - await GetMusic().getMusic1(Authorization: AppData().currentToken); - MusicListBean bean2 = - await GetMusic().getMusic2(Authorization: AppData().currentToken); - MusicListBean bean3 = - await GetMusic().getMusic3(Authorization: AppData().currentToken); + // Stream values + Duration _duration = Duration.zero; + Duration _position = Duration.zero; + // Current song info + late String artistName; + late String musicName; + late bool likesnot; + late bool collectionsnot; + + // Song lists + List id = []; + List song2 = []; + List artist = []; + List music = []; + List likes = []; + List collection = []; + + bool _isLoading = false; + double _bufferProgress = 0.0; + + Future _fetchSonglistData() async { setState(() { - song2 = [bean1.musicPath,bean2.musicPath,bean3.musicPath]; - artist = [bean1.singerName,bean2.singerName,bean3.singerName]; - music = [bean1.name,bean2.name,bean3.name]; - likes = [bean1.likeOrNot,bean2.likeOrNot,bean3.likeOrNot]; - collection = [bean1.collectOrNot,bean2.collectOrNot,bean3.collectOrNot]; + for (int i = 0; i < widget.songList.length; i++) { + id.add(widget.songList[i].id); + song2.add(widget.songList[i].musicurl); + artist.add(widget.songList[i].artist); + music.add(widget.songList[i].title); + likes.add(widget.songList[i].likes); + collection.add(widget.songList[i].collection); + } }); } + String _getFileExtension(String url) { + // Remove query parameters + final urlWithoutQuery = url.split('?').first; + // Get the extension including the dot + final extension = path.extension(urlWithoutQuery); + return extension.isNotEmpty ? extension : '.mp3'; // Default to .mp3 if no extension found + } - late AudioPlayer _audioPlayer; - late Duration _duration; - late Duration _position; late String artistName; - late String musicName; - late bool likesnot; - late bool collectionsnot; + Future _getLocalAudioPath() async { + if (!_isDownloaded) return null; + + final fileName = '${id[currentSongIndex]}_${music[currentSongIndex]}_${artist[currentSongIndex]}'; + final extension = _getFileExtension(song2[currentSongIndex]); + final fullFileName = '$fileName$extension'; + return path.join('/storage/emulated/0/MTMusic', fullFileName); + } + + Future _checkIfDownloaded() async { + try { + final fileName = '${id[currentSongIndex]}_${music[currentSongIndex]}_${artist[currentSongIndex]}'; + final directory = Directory('/storage/emulated/0/MTMusic'); + + if (await directory.exists()) { + final files = directory.listSync(); + final isExists = files.any((file) { + final name = path.basename(file.path); + return name.startsWith(fileName); + }); + + if (mounted) { + setState(() { + _isDownloaded = isExists; + _isDownloading = false; + _downloadProgress = 0.0; + }); + } + } else { + if (mounted) { + setState(() { + _isDownloaded = false; + _isDownloading = false; + _downloadProgress = 0.0; + }); + } + } + } catch (e) { + print('Error checking downloaded file: $e'); + if (mounted) { + setState(() { + _isDownloaded = false; + _isDownloading = false; + _downloadProgress = 0.0; + }); + } + } + } + + Future _updateCurrentSong() async { + // 立即更新UI和歌曲信息 + setState(() { + _isLoading = true; + _position = Duration.zero; + _duration = Duration.zero; + artistName = artist[currentSongIndex]; + musicName = music[currentSongIndex]; + likesnot = likes[currentSongIndex]; + collectionsnot = collection[currentSongIndex]; + }); + + // 异步检查下载状态 + await _checkIfDownloaded(); + + try { + // 在后台停止当前播放 + unawaited(_audioPlayer.stop()); + + // Check for local file first + final localPath = await _getLocalAudioPath(); + final audioSource = localPath != null + ? AudioSource.file(localPath) + : AudioSource.uri(Uri.parse(song2[currentSongIndex])); + + print("-------------" + audioSource.uri.toString()); + + // Set the audio source and get duration + final duration = await _audioPlayer.setAudioSource( + audioSource, + preload: true, + ); + + if (!_isDisposed) { + setState(() { + _duration = duration ?? Duration.zero; + _isLoading = false; + }); + } + + // 开始播放 + await _audioPlayer.play(); + } catch (e) { + print('Error loading audio source: $e'); + if (!_isDisposed) { + setState(() { + _isLoading = false; + }); + } + } + } void playerInit() { - _audioPlayer = AudioPlayer()..setSourceUrl('${widget.song.musicurl}'); - _duration = const Duration(); - _position = const Duration(); - artistName = '${widget.song.artist}'; - musicName = '${widget.song.title}'; - likesnot = widget.song.likes; - collectionsnot = widget.song.collection; - - _audioPlayer.onDurationChanged.listen((Duration d) { - _duration = d; - setState(() {}); + _audioPlayer = AudioPlayer(); + currentSongIndex = widget.initialSongIndex; + + // Initialize with first song + artistName = widget.songList[widget.initialSongIndex].artist; + musicName = widget.songList[widget.initialSongIndex].title; + likesnot = widget.songList[widget.initialSongIndex].likes; + collectionsnot = widget.songList[widget.initialSongIndex].collection; + + // Listen to player events + _audioPlayer.positionStream.listen((position) { + if (!_isDisposed) { + setState(() => _position = position); + } }); - _audioPlayer.onPositionChanged.listen((Duration p) { - _position = p; - setState(() {}); + _audioPlayer.durationStream.listen((duration) { + if (!_isDisposed) { + setState(() => _duration = duration ?? Duration.zero); + } }); - _audioPlayer.onPlayerComplete.listen((event) { - setState(() { - _position = _duration; - }); + _audioPlayer.processingStateStream.listen((state) { + if (state == ProcessingState.completed) { + playNextSong(); + } }); } - void playOrPause() { - if (_audioPlayer.state == PlayerState.playing) { - _audioPlayer.pause(); + Widget _buildPlayButton() { + return SizedBox( + width: 52, + height: 52, + child: Center( + child: _isLoading + ? const CircularProgressIndicator( + valueColor: AlwaysStoppedAnimation(Color(0xff429482)), + strokeWidth: 3.0, + ) + : IconButton( + padding: EdgeInsets.zero, // 移除内边距 + constraints: const BoxConstraints( + minWidth: 52, + minHeight: 52, + maxWidth: 52, + maxHeight: 52, + ), + onPressed: playOrPause, + icon: _audioPlayer.playing + ? Image.asset( + "assets/img/music_play.png", + width: 52, + height: 52, + ) + : Image.asset( + "assets/img/music_pause.png", + width: 52, + height: 52, + ), + ), + ), + ); + } + + void _initBufferingListener() { + _audioPlayer.bufferedPositionStream.listen((bufferedPosition) { + if (!_isDisposed) { + final bufferProgress = _duration.inMilliseconds > 0 + ? bufferedPosition.inMilliseconds / _duration.inMilliseconds + : 0.0; + + setState(() { + _bufferProgress = bufferProgress; + }); + } + }); + } + + void playOrPause() async { + if (_audioPlayer.playing) { + await _audioPlayer.pause(); } else { - _audioPlayer.resume(); + await _audioPlayer.play(); } - setState(() {}); } void playNextSong() { - if (currentSongIndex < 2) { + if (currentSongIndex < widget.songList.length - 1) { currentSongIndex++; } else { currentSongIndex = 0; } - _audioPlayer.setSourceUrl(song2[currentSongIndex]); - artistName = artist[currentSongIndex]; - musicName = music[currentSongIndex]; - likesnot = likes[currentSongIndex]; - collectionsnot = collection[currentSongIndex]; - _audioPlayer.resume(); + _updateCurrentSong(); } void playPreviousSong() { if (currentSongIndex > 0) { currentSongIndex--; } else { - currentSongIndex = 2; + currentSongIndex = widget.songList.length - 1; } - - _audioPlayer.setSourceUrl(song2[currentSongIndex]); - artistName = artist[currentSongIndex]; - musicName = music[currentSongIndex]; - likesnot = likes[currentSongIndex]; - collectionsnot = collection[currentSongIndex]; - _audioPlayer.resume(); + _updateCurrentSong(); } - String formatDuration(Duration duration) { String twoDigits(int n) => n.toString().padLeft(2, "0"); String twoDigitMinutes = twoDigits(duration.inMinutes.remainder(60)); String twoDigitSeconds = twoDigits(duration.inSeconds.remainder(60)); - return "${twoDigits(duration.inMinutes)}:$twoDigitSeconds"; + return "$twoDigitMinutes:$twoDigitSeconds"; + } + + Future _initializeAsync() async { + await _fetchSonglistData(); + await _updateCurrentSong(); } @override void initState() { - playerInit(); - currentSongIndex = widget.initialSongIndex; - _fetchSonglistData(); super.initState(); + playerInit(); + _initBufferingListener(); + _initializeAsync(); } @override void dispose() { _isDisposed = true; - _audioPlayer.release(); _audioPlayer.dispose(); super.dispose(); } + void _changeCurrentSong(int index) { + if (!_isDisposed) { + setState(() { + currentSongIndex = index; + _updateCurrentSong(); + }); + } + } @override Widget build(BuildContext context) { return Container( @@ -189,9 +362,60 @@ class _MusicViewState extends State { ), ), IconButton( - onPressed: () {}, - icon: Image.asset( - "assets/img/music_download.png", + onPressed: _isDownloading || _isDownloaded ? null: () async { + setState(() { + _isDownloading = true; + _downloadProgress = 0; + }); + + final downloadApi = DownloadApi(); + final fileName = '${id[currentSongIndex]}_${music[currentSongIndex]}_${artist[currentSongIndex]}'; + final filePath = await downloadApi.downloadMusic( + musicUrl: song2[currentSongIndex], + name: fileName, + context: context, + onProgress: (progress) { // 添加进度回调 + setState(() { + _downloadProgress = progress; + }); + }, + ); + + setState(() { + _isDownloading = false; + }); + + if (filePath != null) { + setState(() { + _isDownloaded = true; + }); + } + }, + + icon: _isDownloading + ? Stack( + alignment: Alignment.center, + children: [ + SizedBox( + width: 32, + height: 32, + child: CircularProgressIndicator( + value: _downloadProgress, + backgroundColor: Colors.grey[200], + valueColor: AlwaysStoppedAnimation(Color(0xff429482)), + strokeWidth: 3.0, + ), + ), + Text( + '${(_downloadProgress * 100).toInt()}', + style: TextStyle(fontSize: 12), + ), + ], + ) + : Image.asset( + _isDownloaded + ? "assets/img/music_download_completed.png" // 已下载显示完成图标 + : "assets/img/music_download.png", // 未下载显示下载图标 width: 30, height: 30, ), @@ -220,7 +444,7 @@ class _MusicViewState extends State { child: ClipRRect( borderRadius: BorderRadius.circular(80), child: Image.network( - '${widget.song.artistPic}', + widget.songList[currentSongIndex].artistPic, width: 230, height: 230, fit: BoxFit.cover, @@ -298,7 +522,7 @@ class _MusicViewState extends State { ], ), const SizedBox( - height: 60, + height: 80, ), Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, @@ -367,15 +591,7 @@ class _MusicViewState extends State { const SizedBox( width: 10, ), - IconButton( - onPressed: playOrPause, - icon: _audioPlayer.state == PlayerState.playing - ? Image.asset( - "assets/img/music_play.png", - ) - : Image.asset( - "assets/img/music_pause.png", - )), + _buildPlayButton(), // 这里使用新的方法替换原来的IconButton const SizedBox( width: 10, ), @@ -485,19 +701,4 @@ class _MusicViewState extends State { }, ); } - - void _changeCurrentSong(int index) { - if (!_isDisposed) { // Check the flag before using the player - setState(() { - currentSongIndex = index; - _audioPlayer.setSourceUrl(song2[currentSongIndex]); - artistName = artist[currentSongIndex]; - musicName = music[currentSongIndex]; - likesnot = likes[currentSongIndex]; - collectionsnot = collection[currentSongIndex]; - _audioPlayer.resume(); - }); - } - } - } diff --git a/macos/Flutter/GeneratedPluginRegistrant.swift b/macos/Flutter/GeneratedPluginRegistrant.swift index 80739ac..8a04889 100644 --- a/macos/Flutter/GeneratedPluginRegistrant.swift +++ b/macos/Flutter/GeneratedPluginRegistrant.swift @@ -5,12 +5,16 @@ import FlutterMacOS import Foundation +import audio_session import audioplayers_darwin import file_selector_macos +import just_audio import path_provider_foundation func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { + AudioSessionPlugin.register(with: registry.registrar(forPlugin: "AudioSessionPlugin")) AudioplayersDarwinPlugin.register(with: registry.registrar(forPlugin: "AudioplayersDarwinPlugin")) FileSelectorPlugin.register(with: registry.registrar(forPlugin: "FileSelectorPlugin")) + JustAudioPlugin.register(with: registry.registrar(forPlugin: "JustAudioPlugin")) PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) } diff --git a/pubspec.lock b/pubspec.lock index 1902b87..9dd8006 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -6,15 +6,23 @@ packages: description: name: async sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "2.11.0" + audio_session: + dependency: transitive + description: + name: audio_session + sha256: "343e83bc7809fbda2591a49e525d6b63213ade10c76f15813be9aed6657b3261" + url: "https://pub.dev" + source: hosted + version: "0.1.21" audioplayers: dependency: "direct main" description: name: audioplayers sha256: c05c6147124cd63e725e861335a8b4d57300b80e6e92cea7c145c739223bbaef - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "5.2.1" audioplayers_android: @@ -22,7 +30,7 @@ packages: description: name: audioplayers_android sha256: b00e1a0e11365d88576320ec2d8c192bc21f1afb6c0e5995d1c57ae63156acb5 - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "4.0.3" audioplayers_darwin: @@ -30,7 +38,7 @@ packages: description: name: audioplayers_darwin sha256: "3034e99a6df8d101da0f5082dcca0a2a99db62ab1d4ddb3277bed3f6f81afe08" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "5.0.2" audioplayers_linux: @@ -38,7 +46,7 @@ packages: description: name: audioplayers_linux sha256: "60787e73fefc4d2e0b9c02c69885402177e818e4e27ef087074cf27c02246c9e" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "3.1.0" audioplayers_platform_interface: @@ -46,7 +54,7 @@ packages: description: name: audioplayers_platform_interface sha256: "365c547f1bb9e77d94dd1687903a668d8f7ac3409e48e6e6a3668a1ac2982adb" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "6.1.0" audioplayers_web: @@ -54,7 +62,7 @@ packages: description: name: audioplayers_web sha256: "22cd0173e54d92bd9b2c80b1204eb1eb159ece87475ab58c9788a70ec43c2a62" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "4.1.0" audioplayers_windows: @@ -62,7 +70,7 @@ packages: description: name: audioplayers_windows sha256: "9536812c9103563644ada2ef45ae523806b0745f7a78e89d1b5fb1951de90e1a" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "3.1.0" boolean_selector: @@ -70,7 +78,7 @@ packages: description: name: boolean_selector sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "2.1.1" characters: @@ -78,7 +86,7 @@ packages: description: name: characters sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.3.0" clock: @@ -86,113 +94,129 @@ packages: description: name: clock sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.1.1" collection: dependency: transitive description: name: collection - sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 - url: "https://pub.flutter-io.cn" + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a + url: "https://pub.dev" source: hosted - version: "1.17.2" + version: "1.18.0" cross_file: dependency: transitive description: name: cross_file - sha256: "2f9d2cbccb76127ba28528cb3ae2c2326a122446a83de5a056aaa3880d3882c5" - url: "https://pub.flutter-io.cn" + sha256: "7caf6a750a0c04effbb52a676dce9a4a592e10ad35c34d6d2d0e4811160d5670" + url: "https://pub.dev" source: hosted - version: "0.3.3+7" + version: "0.3.4+2" crypto: dependency: transitive description: name: crypto - sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab - url: "https://pub.flutter-io.cn" + sha256: "1e445881f28f22d6140f181e07737b22f1e099a5e1ff94b0af2f9e4a463f4855" + url: "https://pub.dev" source: hosted - version: "3.0.3" + version: "3.0.6" cupertino_icons: dependency: "direct main" description: name: cupertino_icons - sha256: d57953e10f9f8327ce64a508a355f0b1ec902193f66288e8cb5070e7c47eeb2d - url: "https://pub.flutter-io.cn" + sha256: ba631d1c7f7bef6b729a622b7b752645a2d076dba9976925b8f25725a30e1ee6 + url: "https://pub.dev" source: hosted - version: "1.0.6" + version: "1.0.8" dio: dependency: "direct main" description: name: dio - sha256: "797e1e341c3dd2f69f2dad42564a6feff3bfb87187d05abb93b9609e6f1645c3" - url: "https://pub.flutter-io.cn" + sha256: "5598aa796bbf4699afd5c67c0f5f6e2ed542afc956884b9cd58c306966efc260" + url: "https://pub.dev" source: hosted - version: "5.4.0" + version: "5.7.0" + dio_web_adapter: + dependency: transitive + description: + name: dio_web_adapter + sha256: "33259a9276d6cea88774a0000cfae0d861003497755969c92faa223108620dc8" + url: "https://pub.dev" + source: hosted + version: "2.0.0" fake_async: dependency: transitive description: name: fake_async sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.3.1" ffi: dependency: transitive description: name: ffi - sha256: "7bf0adc28a23d395f19f3f1eb21dd7cfd1dd9f8e1c50051c069122e6853bc878" - url: "https://pub.flutter-io.cn" + sha256: "16ed7b077ef01ad6170a3d0c57caa4a112a38d7a2ed5602e0aca9ca6f3d98da6" + url: "https://pub.dev" source: hosted - version: "2.1.0" + version: "2.1.3" file: dependency: transitive description: name: file - sha256: "5fc22d7c25582e38ad9a8515372cd9a93834027aacf1801cf01164dac0ffa08c" - url: "https://pub.flutter-io.cn" + sha256: a3b4f84adafef897088c160faf7dfffb7696046cb13ae90b508c2cbc95d3b8d4 + url: "https://pub.dev" source: hosted - version: "7.0.0" + version: "7.0.1" file_picker: dependency: "direct main" description: name: file_picker - sha256: "4e42aacde3b993c5947467ab640882c56947d9d27342a5b6f2895b23956954a6" - url: "https://pub.flutter-io.cn" + sha256: "1bbf65dd997458a08b531042ec3794112a6c39c07c37ff22113d2e7e4f81d4e4" + url: "https://pub.dev" source: hosted - version: "6.1.1" + version: "6.2.1" file_selector_linux: dependency: transitive description: name: file_selector_linux - sha256: "045d372bf19b02aeb69cacf8b4009555fb5f6f0b7ad8016e5f46dd1387ddd492" - url: "https://pub.flutter-io.cn" + sha256: "712ce7fab537ba532c8febdb1a8f167b32441e74acd68c3ccb2e36dcb52c4ab2" + url: "https://pub.dev" source: hosted - version: "0.9.2+1" + version: "0.9.3" file_selector_macos: dependency: transitive description: name: file_selector_macos - sha256: b15c3da8bd4908b9918111fa486903f5808e388b8d1c559949f584725a6594d6 - url: "https://pub.flutter-io.cn" + sha256: "271ab9986df0c135d45c3cdb6bd0faa5db6f4976d3e4b437cf7d0f258d941bfc" + url: "https://pub.dev" source: hosted - version: "0.9.3+3" + version: "0.9.4+2" file_selector_platform_interface: dependency: transitive description: name: file_selector_platform_interface - sha256: "0aa47a725c346825a2bd396343ce63ac00bda6eff2fbc43eabe99737dede8262" - url: "https://pub.flutter-io.cn" + sha256: a3994c26f10378a039faa11de174d7b78eb8f79e4dd0af2a451410c1a5c3f66b + url: "https://pub.dev" source: hosted - version: "2.6.1" + version: "2.6.2" file_selector_windows: dependency: transitive description: name: file_selector_windows - sha256: d3547240c20cabf205c7c7f01a50ecdbc413755814d6677f3cb366f04abcead0 - url: "https://pub.flutter-io.cn" + sha256: "8f5d2f6590d51ecd9179ba39c64f722edc15226cc93dcc8698466ad36a4a85a4" + url: "https://pub.dev" source: hosted - version: "0.9.3+1" + version: "0.9.3+3" + fixnum: + dependency: transitive + description: + name: fixnum + sha256: b6dc7065e46c974bc7c5f143080a6764ec7a4be6da1285ececdc37be96de53be + url: "https://pub.dev" + source: hosted + version: "1.1.1" flutter: dependency: "direct main" description: flutter @@ -203,23 +227,23 @@ packages: description: name: flutter_lints sha256: a25a15ebbdfc33ab1cd26c63a6ee519df92338a9c10f122adda92938253bef04 - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "2.0.3" flutter_plugin_android_lifecycle: dependency: transitive description: name: flutter_plugin_android_lifecycle - sha256: b068ffc46f82a55844acfa4fdbb61fad72fa2aef0905548419d97f0f95c456da - url: "https://pub.flutter-io.cn" + sha256: "9b78450b89f059e96c9ebb355fa6b3df1d6b330436e0b885fb49594c41721398" + url: "https://pub.dev" source: hosted - version: "2.0.17" + version: "2.0.23" flutter_swiper_view: dependency: "direct main" description: name: flutter_swiper_view sha256: "2a165b259e8a4c49d4da5626b967ed42a73dac2d075bd9e266ad8d23b9f01879" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.1.8" flutter_test: @@ -237,7 +261,7 @@ packages: description: name: get sha256: e4e7335ede17452b391ed3b2ede016545706c01a02292a6c97619705e7d2a85e - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "4.6.6" get_storage: @@ -245,63 +269,63 @@ packages: description: name: get_storage sha256: "39db1fffe779d0c22b3a744376e86febe4ade43bf65e06eab5af707dc84185a2" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "2.1.1" http: dependency: "direct main" description: name: http - sha256: "759d1a329847dd0f39226c688d3e06a6b8679668e350e2891a6474f8b4bb8525" - url: "https://pub.flutter-io.cn" + sha256: b9c29a161230ee03d3ccf545097fccd9b87a5264228c5d348202e0f0c28f9010 + url: "https://pub.dev" source: hosted - version: "1.1.0" + version: "1.2.2" http_parser: dependency: "direct main" description: name: http_parser sha256: "2aa08ce0341cc9b354a498388e30986515406668dbcc4f7c950c3e715496693b" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "4.0.2" image_picker: dependency: "direct main" description: name: image_picker - sha256: "7d7f2768df2a8b0a3cefa5ef4f84636121987d403130e70b17ef7e2cf650ba84" - url: "https://pub.flutter-io.cn" + sha256: "021834d9c0c3de46bf0fe40341fa07168407f694d9b2bb18d532dc1261867f7a" + url: "https://pub.dev" source: hosted - version: "1.0.4" + version: "1.1.2" image_picker_android: dependency: transitive description: name: image_picker_android - sha256: d6a6e78821086b0b737009b09363018309bbc6de3fd88cc5c26bc2bb44a4957f - url: "https://pub.flutter-io.cn" + sha256: "8faba09ba361d4b246dc0a17cb4289b3324c2b9f6db7b3d457ee69106a86bd32" + url: "https://pub.dev" source: hosted - version: "0.8.8+2" + version: "0.8.12+17" image_picker_for_web: dependency: transitive description: name: image_picker_for_web - sha256: "50bc9ae6a77eea3a8b11af5eb6c661eeb858fdd2f734c2a4fd17086922347ef7" - url: "https://pub.flutter-io.cn" + sha256: "717eb042ab08c40767684327be06a5d8dbb341fe791d514e4b92c7bbe1b7bb83" + url: "https://pub.dev" source: hosted - version: "3.0.1" + version: "3.0.6" image_picker_ios: dependency: transitive description: name: image_picker_ios - sha256: "76ec722aeea419d03aa915c2c96bf5b47214b053899088c9abb4086ceecf97a7" - url: "https://pub.flutter-io.cn" + sha256: "4f0568120c6fcc0aaa04511cb9f9f4d29fc3d0139884b1d06be88dcec7641d6b" + url: "https://pub.dev" source: hosted - version: "0.8.8+4" + version: "0.8.12+1" image_picker_linux: dependency: transitive description: name: image_picker_linux sha256: "4ed1d9bb36f7cd60aa6e6cd479779cc56a4cb4e4de8f49d487b1aaad831300fa" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "0.2.1+1" image_picker_macos: @@ -309,23 +333,23 @@ packages: description: name: image_picker_macos sha256: "3f5ad1e8112a9a6111c46d0b57a7be2286a9a07fc6e1976fdf5be2bd31d4ff62" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "0.2.1+1" image_picker_platform_interface: dependency: transitive description: name: image_picker_platform_interface - sha256: ed9b00e63977c93b0d2d2b343685bed9c324534ba5abafbb3dfbd6a780b1b514 - url: "https://pub.flutter-io.cn" + sha256: "9ec26d410ff46f483c5519c29c02ef0e02e13a543f882b152d4bfd2f06802f80" + url: "https://pub.dev" source: hosted - version: "2.9.1" + version: "2.10.0" image_picker_windows: dependency: transitive description: name: image_picker_windows sha256: "6ad07afc4eb1bc25f3a01084d28520496c4a3bb0cb13685435838167c9dcedeb" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "0.2.1+1" js: @@ -333,137 +357,241 @@ packages: description: name: js sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3 - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "0.6.7" + just_audio: + dependency: "direct main" + description: + name: just_audio + sha256: a49e7120b95600bd357f37a2bb04cd1e88252f7cdea8f3368803779b925b1049 + url: "https://pub.dev" + source: hosted + version: "0.9.42" + just_audio_platform_interface: + dependency: transitive + description: + name: just_audio_platform_interface + sha256: "0243828cce503c8366cc2090cefb2b3c871aa8ed2f520670d76fd47aa1ab2790" + url: "https://pub.dev" + source: hosted + version: "4.3.0" + just_audio_web: + dependency: transitive + description: + name: just_audio_web + sha256: "9a98035b8b24b40749507687520ec5ab404e291d2b0937823ff45d92cb18d448" + url: "https://pub.dev" + source: hosted + version: "0.4.13" + leak_tracker: + dependency: transitive + description: + name: leak_tracker + sha256: "3f87a60e8c63aecc975dda1ceedbc8f24de75f09e4856ea27daf8958f2f0ce05" + url: "https://pub.dev" + source: hosted + version: "10.0.5" + leak_tracker_flutter_testing: + dependency: transitive + description: + name: leak_tracker_flutter_testing + sha256: "932549fb305594d82d7183ecd9fa93463e9914e1b67cacc34bc40906594a1806" + url: "https://pub.dev" + source: hosted + version: "3.0.5" + leak_tracker_testing: + dependency: transitive + description: + name: leak_tracker_testing + sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3" + url: "https://pub.dev" + source: hosted + version: "3.0.1" lints: dependency: transitive description: name: lints sha256: "0a217c6c989d21039f1498c3ed9f3ed71b354e69873f13a8dfc3c9fe76f1b452" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "2.1.1" matcher: dependency: transitive description: name: matcher - sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e" - url: "https://pub.flutter-io.cn" + sha256: d2323aa2060500f906aa31a895b4030b6da3ebdcc5619d14ce1aada65cd161cb + url: "https://pub.dev" source: hosted - version: "0.12.16" + version: "0.12.16+1" material_color_utilities: dependency: transitive description: name: material_color_utilities - sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" - url: "https://pub.flutter-io.cn" + sha256: f7142bb1154231d7ea5f96bc7bde4bda2a0945d2806bb11670e30b850d56bdec + url: "https://pub.dev" source: hosted - version: "0.5.0" + version: "0.11.1" meta: dependency: transitive description: name: meta - sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" - url: "https://pub.flutter-io.cn" + sha256: bdb68674043280c3428e9ec998512fb681678676b3c54e773629ffe74419f8c7 + url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.15.0" mime: dependency: transitive description: name: mime - sha256: e4ff8e8564c03f255408decd16e7899da1733852a9110a58fe6d1b817684a63e - url: "https://pub.flutter-io.cn" + sha256: "41a20518f0cb1256669420fdba0cd90d21561e560ac240f26ef8322e45bb7ed6" + url: "https://pub.dev" source: hosted - version: "1.0.4" + version: "2.0.0" nested: dependency: transitive description: name: nested sha256: "03bac4c528c64c95c722ec99280375a6f2fc708eec17c7b3f07253b626cd2a20" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.0.0" path: dependency: "direct main" description: name: path - sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917" - url: "https://pub.flutter-io.cn" + sha256: "087ce49c3f0dc39180befefc60fdb4acd8f8620e5682fe2476afd0b3688bb4af" + url: "https://pub.dev" source: hosted - version: "1.8.3" + version: "1.9.0" path_provider: dependency: transitive description: name: path_provider - sha256: a1aa8aaa2542a6bc57e381f132af822420216c80d4781f7aa085ca3229208aaa - url: "https://pub.flutter-io.cn" + sha256: fec0d61223fba3154d87759e3cc27fe2c8dc498f6386c6d6fc80d1afdd1bf378 + url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.4" path_provider_android: dependency: transitive description: name: path_provider_android - sha256: e595b98692943b4881b219f0a9e3945118d3c16bd7e2813f98ec6e532d905f72 - url: "https://pub.flutter-io.cn" + sha256: c464428172cb986b758c6d1724c603097febb8fb855aa265aeecc9280c294d4a + url: "https://pub.dev" source: hosted - version: "2.2.1" + version: "2.2.12" path_provider_foundation: dependency: transitive description: name: path_provider_foundation - sha256: "19314d595120f82aca0ba62787d58dde2cc6b5df7d2f0daf72489e38d1b57f2d" - url: "https://pub.flutter-io.cn" + sha256: f234384a3fdd67f989b4d54a5d73ca2a6c422fa55ae694381ae0f4375cd1ea16 + url: "https://pub.dev" source: hosted - version: "2.3.1" + version: "2.4.0" path_provider_linux: dependency: transitive description: name: path_provider_linux sha256: f7a1fe3a634fe7734c8d3f2766ad746ae2a2884abe22e241a8b301bf5cac3279 - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "2.2.1" path_provider_platform_interface: dependency: transitive description: name: path_provider_platform_interface - sha256: "94b1e0dd80970c1ce43d5d4e050a9918fce4f4a775e6142424c30a29a363265c" - url: "https://pub.flutter-io.cn" + sha256: "88f5779f72ba699763fa3a3b06aa4bf6de76c8e5de842cf6f29e2e06476c2334" + url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.2" path_provider_windows: dependency: transitive description: name: path_provider_windows - sha256: "8bc9f22eee8690981c22aa7fc602f5c85b497a6fb2ceb35ee5a5e5ed85ad8170" - url: "https://pub.flutter-io.cn" + sha256: bd6f00dbd873bfb70d0761682da2b3a2c2fccc2b9e84c495821639601d81afe7 + url: "https://pub.dev" source: hosted - version: "2.2.1" + version: "2.3.0" + permission_handler: + dependency: "direct main" + description: + name: permission_handler + sha256: "18bf33f7fefbd812f37e72091a15575e72d5318854877e0e4035a24ac1113ecb" + url: "https://pub.dev" + source: hosted + version: "11.3.1" + permission_handler_android: + dependency: transitive + description: + name: permission_handler_android + sha256: "71bbecfee799e65aff7c744761a57e817e73b738fedf62ab7afd5593da21f9f1" + url: "https://pub.dev" + source: hosted + version: "12.0.13" + permission_handler_apple: + dependency: transitive + description: + name: permission_handler_apple + sha256: e6f6d73b12438ef13e648c4ae56bd106ec60d17e90a59c4545db6781229082a0 + url: "https://pub.dev" + source: hosted + version: "9.4.5" + permission_handler_html: + dependency: transitive + description: + name: permission_handler_html + sha256: af26edbbb1f2674af65a8f4b56e1a6f526156bc273d0e65dd8075fab51c78851 + url: "https://pub.dev" + source: hosted + version: "0.1.3+2" + permission_handler_platform_interface: + dependency: transitive + description: + name: permission_handler_platform_interface + sha256: e9c8eadee926c4532d0305dff94b85bf961f16759c3af791486613152af4b4f9 + url: "https://pub.dev" + source: hosted + version: "4.2.3" + permission_handler_windows: + dependency: transitive + description: + name: permission_handler_windows + sha256: "1a790728016f79a41216d88672dbc5df30e686e811ad4e698bfc51f76ad91f1e" + url: "https://pub.dev" + source: hosted + version: "0.2.1" platform: dependency: transitive description: name: platform - sha256: "0a279f0707af40c890e80b1e9df8bb761694c074ba7e1d4ab1bc4b728e200b59" - url: "https://pub.flutter-io.cn" + sha256: "5d6b1b0036a5f331ebc77c850ebc8506cbc1e9416c27e59b439f917a902a4984" + url: "https://pub.dev" source: hosted - version: "3.1.3" + version: "3.1.6" plugin_platform_interface: dependency: transitive description: name: plugin_platform_interface - sha256: f4f88d4a900933e7267e2b353594774fc0d07fb072b47eedcd5b54e1ea3269f8 - url: "https://pub.flutter-io.cn" + sha256: "4820fbfdb9478b1ebae27888254d445073732dae3d6ea81f0b7e06d5dedc3f02" + url: "https://pub.dev" source: hosted - version: "2.1.7" + version: "2.1.8" provider: dependency: "direct main" description: name: provider - sha256: "9a96a0a19b594dbc5bf0f1f27d2bc67d5f95957359b461cd9feb44ed6ae75096" - url: "https://pub.flutter-io.cn" + sha256: c8a055ee5ce3fd98d6fc872478b03823ffdb448699c6ebdbbc71d59b596fd48c + url: "https://pub.dev" + source: hosted + version: "6.1.2" + rxdart: + dependency: transitive + description: + name: rxdart + sha256: "5c3004a4a8dbb94bd4bf5412a4def4acdaa12e12f269737a5751369e12d1a962" + url: "https://pub.dev" source: hosted - version: "6.1.1" + version: "0.28.0" sky_engine: dependency: transitive description: flutter @@ -474,7 +602,7 @@ packages: description: name: source_span sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.10.0" sprintf: @@ -482,105 +610,113 @@ packages: description: name: sprintf sha256: "1fc9ffe69d4df602376b52949af107d8f5703b77cda567c4d7d86a0693120f23" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "7.0.0" stack_trace: dependency: transitive description: name: stack_trace - sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 - url: "https://pub.flutter-io.cn" + sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b" + url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.11.1" stream_channel: dependency: transitive description: name: stream_channel - sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" - url: "https://pub.flutter-io.cn" + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 + url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.2" string_scanner: dependency: transitive description: name: string_scanner sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.2.0" synchronized: dependency: transitive description: name: synchronized - sha256: "5fcbd27688af6082f5abd611af56ee575342c30e87541d0245f7ff99faa02c60" - url: "https://pub.flutter-io.cn" + sha256: "69fe30f3a8b04a0be0c15ae6490fc859a78ef4c43ae2dd5e8a623d45bfcf9225" + url: "https://pub.dev" source: hosted - version: "3.1.0" + version: "3.3.0+3" term_glyph: dependency: transitive description: name: term_glyph sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84 - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "1.2.1" test_api: dependency: transitive description: name: test_api - sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" - url: "https://pub.flutter-io.cn" + sha256: "5b8a98dafc4d5c4c9c72d8b31ab2b23fc13422348d2997120294d3bac86b4ddb" + url: "https://pub.dev" source: hosted - version: "0.6.0" + version: "0.7.2" typed_data: dependency: transitive description: name: typed_data - sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c - url: "https://pub.flutter-io.cn" + sha256: f9049c039ebfeb4cf7a7104a675823cd72dba8297f264b6637062516699fa006 + url: "https://pub.dev" source: hosted - version: "1.3.2" + version: "1.4.0" uuid: dependency: transitive description: name: uuid - sha256: df5a4d8f22ee4ccd77f8839ac7cb274ebc11ef9adcce8b92be14b797fe889921 - url: "https://pub.flutter-io.cn" + sha256: a5be9ef6618a7ac1e964353ef476418026db906c4facdedaa299b7a2e71690ff + url: "https://pub.dev" source: hosted - version: "4.2.1" + version: "4.5.1" vector_math: dependency: transitive description: name: vector_math sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803" - url: "https://pub.flutter-io.cn" + url: "https://pub.dev" source: hosted version: "2.1.4" + vm_service: + dependency: transitive + description: + name: vm_service + sha256: "5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d" + url: "https://pub.dev" + source: hosted + version: "14.2.5" web: dependency: transitive description: name: web - sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 - url: "https://pub.flutter-io.cn" + sha256: cd3543bd5798f6ad290ea73d210f423502e71900302dde696f8bff84bf89a1cb + url: "https://pub.dev" source: hosted - version: "0.1.4-beta" + version: "1.1.0" win32: dependency: transitive description: name: win32 - sha256: "7c99c0e1e2fa190b48d25c81ca5e42036d5cac81430ef249027d97b0935c553f" - url: "https://pub.flutter-io.cn" + sha256: "10169d3934549017f0ae278ccb07f828f9d6ea21573bab0fb77b0e1ef0fce454" + url: "https://pub.dev" source: hosted - version: "5.1.0" + version: "5.7.2" xdg_directories: dependency: transitive description: name: xdg_directories - sha256: "589ada45ba9e39405c198fe34eb0f607cddb2108527e658136120892beac46d2" - url: "https://pub.flutter-io.cn" + sha256: "7a3f37b05d989967cdddcbb571f1ea834867ae2faa29725fd085180e0883aa15" + url: "https://pub.dev" source: hosted - version: "1.0.3" + version: "1.1.0" sdks: - dart: ">=3.1.2 <4.0.0" - flutter: ">=3.13.0" + dart: ">=3.5.0 <4.0.0" + flutter: ">=3.24.0" diff --git a/pubspec.yaml b/pubspec.yaml index c825d0c..f212b9d 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -33,7 +33,8 @@ dependencies: flutter_swiper_view: 1.1.8 audioplayers: ^5.2.1 - + permission_handler: ^11.0.1 + just_audio: ^0.9.34 # The following adds the Cupertino Icons font to your application. diff --git a/windows/flutter/CMakeLists.txt b/windows/flutter/CMakeLists.txt index 930d207..903f489 100644 --- a/windows/flutter/CMakeLists.txt +++ b/windows/flutter/CMakeLists.txt @@ -10,6 +10,11 @@ include(${EPHEMERAL_DIR}/generated_config.cmake) # https://github.com/flutter/flutter/issues/57146. set(WRAPPER_ROOT "${EPHEMERAL_DIR}/cpp_client_wrapper") +# Set fallback configurations for older versions of the flutter tool. +if (NOT DEFINED FLUTTER_TARGET_PLATFORM) + set(FLUTTER_TARGET_PLATFORM "windows-x64") +endif() + # === Flutter Library === set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/flutter_windows.dll") @@ -92,7 +97,7 @@ add_custom_command( COMMAND ${CMAKE_COMMAND} -E env ${FLUTTER_TOOL_ENVIRONMENT} "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.bat" - windows-x64 $ + ${FLUTTER_TARGET_PLATFORM} $ VERBATIM ) add_custom_target(flutter_assemble DEPENDS diff --git a/windows/flutter/generated_plugin_registrant.cc b/windows/flutter/generated_plugin_registrant.cc index 5783469..086e60b 100644 --- a/windows/flutter/generated_plugin_registrant.cc +++ b/windows/flutter/generated_plugin_registrant.cc @@ -8,10 +8,13 @@ #include #include +#include void RegisterPlugins(flutter::PluginRegistry* registry) { AudioplayersWindowsPluginRegisterWithRegistrar( registry->GetRegistrarForPlugin("AudioplayersWindowsPlugin")); FileSelectorWindowsRegisterWithRegistrar( registry->GetRegistrarForPlugin("FileSelectorWindows")); + PermissionHandlerWindowsPluginRegisterWithRegistrar( + registry->GetRegistrarForPlugin("PermissionHandlerWindowsPlugin")); } diff --git a/windows/flutter/generated_plugins.cmake b/windows/flutter/generated_plugins.cmake index 786e173..10878d3 100644 --- a/windows/flutter/generated_plugins.cmake +++ b/windows/flutter/generated_plugins.cmake @@ -5,6 +5,7 @@ list(APPEND FLUTTER_PLUGIN_LIST audioplayers_windows file_selector_windows + permission_handler_windows ) list(APPEND FLUTTER_FFI_PLUGIN_LIST