From 128c9201bda0efae89cc627bdd841a5313e921dd Mon Sep 17 00:00:00 2001 From: guozhigq Date: Mon, 10 Jun 2024 13:36:23 +0800 Subject: [PATCH 1/5] =?UTF-8?q?fix:=20=E8=AF=84=E8=AE=BA=E6=A1=86=E5=AE=89?= =?UTF-8?q?=E5=85=A8=E8=B7=9D=E7=A6=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/pages/video/detail/reply_new/view.dart | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/pages/video/detail/reply_new/view.dart b/lib/pages/video/detail/reply_new/view.dart index a136f623..d55e2c1c 100644 --- a/lib/pages/video/detail/reply_new/view.dart +++ b/lib/pages/video/detail/reply_new/view.dart @@ -214,7 +214,15 @@ class _VideoReplyNewDialogState extends State ), Container( height: 52, - padding: const EdgeInsets.only(left: 12, right: 12), + padding: const EdgeInsets.only( + left: 12, + right: 12, + ), + margin: EdgeInsets.only( + bottom: toolbarType == 'input' && keyboardHeight == 0.0 + ? MediaQuery.of(context).padding.bottom + : 0, + ), child: Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ From e47816d0c8f748411779bde717de2e2d72c51250 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Mon, 10 Jun 2024 14:18:59 +0800 Subject: [PATCH 2/5] =?UTF-8?q?opt:=20=E4=B8=80=E9=94=AE=E4=B8=89=E8=BF=9E?= =?UTF-8?q?=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/pages/video/detail/introduction/view.dart | 33 ++++++++++++++----- .../introduction/widgets/action_item.dart | 2 +- 2 files changed, 25 insertions(+), 10 deletions(-) diff --git a/lib/pages/video/detail/introduction/view.dart b/lib/pages/video/detail/introduction/view.dart index 3b89d1de..93cc26c9 100644 --- a/lib/pages/video/detail/introduction/view.dart +++ b/lib/pages/video/detail/introduction/view.dart @@ -571,8 +571,8 @@ class _VideoInfoState extends State with TickerProviderStateMixin { Widget progressWidget(progress) { return SizedBox( - width: 33, - height: 33, + width: const IconThemeData.fallback().size! + 5, + height: const IconThemeData.fallback().size! + 5, child: CircularProgressIndicator( value: progress.value, strokeWidth: 2, @@ -587,14 +587,19 @@ class _VideoInfoState extends State with TickerProviderStateMixin { ColorScheme colorScheme = Theme.of(context).colorScheme; return Stack( children: [ - Positioned(child: progressWidget(_progress), top: 15, left: 24), + Positioned( + top: ((Get.size.width - 24) / 5) / 2 - + (const IconThemeData.fallback().size!), + left: ((Get.size.width - 24) / 5) / 2 - + (const IconThemeData.fallback().size! + 5) / 2, + child: progressWidget(_progress)), InkWell( onTapDown: (details) { feedBack(); - // if (videoIntroController.userInfo == null) { - // SmartDialog.showToast('账号未登录'); - // return; - // } + if (videoIntroController.userInfo == null) { + SmartDialog.showToast('账号未登录'); + return; + } _controller.forward(); }, onTapUp: (TapUpDetails details) { @@ -651,7 +656,12 @@ class _VideoInfoState extends State with TickerProviderStateMixin { 'coin': Obx( () => Stack( children: [ - Positioned(child: progressWidget(_progress), top: 15, left: 24), + Positioned( + top: ((Get.size.width - 24) / 5) / 2 - + (const IconThemeData.fallback().size!), + left: ((Get.size.width - 24) / 5) / 2 - + (const IconThemeData.fallback().size! + 5) / 2, + child: progressWidget(_progress)), ActionItem( icon: Image.asset('assets/images/coin.png', width: 30), onTap: handleState(videoIntroController.actionCoinVideo), @@ -664,7 +674,12 @@ class _VideoInfoState extends State with TickerProviderStateMixin { 'collect': Obx( () => Stack( children: [ - Positioned(child: progressWidget(_progress), top: 15, left: 24), + Positioned( + top: ((Get.size.width - 24) / 5) / 2 - + (const IconThemeData.fallback().size!), + left: ((Get.size.width - 24) / 5) / 2 - + (const IconThemeData.fallback().size! + 5) / 2, + child: progressWidget(_progress)), ActionItem( icon: const Icon(Icons.star_border), selectIcon: const Icon(Icons.star), diff --git a/lib/pages/video/detail/introduction/widgets/action_item.dart b/lib/pages/video/detail/introduction/widgets/action_item.dart index af409dfc..3288b2fa 100644 --- a/lib/pages/video/detail/introduction/widgets/action_item.dart +++ b/lib/pages/video/detail/introduction/widgets/action_item.dart @@ -55,7 +55,7 @@ class ActionItem extends StatelessWidget { : Image.asset( key: ValueKey(selectStatus), 'assets/images/coin.png', - width: 25, + width: const IconThemeData.fallback().size, color: selectStatus ? Theme.of(context).colorScheme.primary : Theme.of(context).colorScheme.outline, From beb5945135209ce70a20f48b37f18745b1200298 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Tue, 11 Jun 2024 00:06:49 +0800 Subject: [PATCH 3/5] =?UTF-8?q?fix:=20=E7=BD=91=E7=BB=9C=E5=BC=82=E5=B8=B8?= =?UTF-8?q?=E6=97=B6=E7=99=BB=E5=BD=95=E7=8A=B6=E6=80=81=E9=87=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/pages/mine/controller.dart | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/pages/mine/controller.dart b/lib/pages/mine/controller.dart index 75c50d82..e682a7e5 100644 --- a/lib/pages/mine/controller.dart +++ b/lib/pages/mine/controller.dart @@ -57,8 +57,6 @@ class MineController extends GetxController { } else { resetUserInfo(); } - } else { - resetUserInfo(); } await queryUserStatOwner(); return res; From 7af1ebd3d5fd63d4dab2b5ec8dc0356dd02046d7 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Tue, 11 Jun 2024 22:59:07 +0800 Subject: [PATCH 4/5] =?UTF-8?q?fix:=20=E5=BC=B9=E5=B9=95=E6=98=BE=E7=A4=BA?= =?UTF-8?q?&=E5=BC=B9=E5=B9=95=E8=AE=BE=E7=BD=AE=E7=BC=93=E5=AD=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/pages/video/detail/view.dart | 41 +++++++++++-------- .../video/detail/widgets/header_control.dart | 4 +- lib/plugin/pl_player/controller.dart | 17 +++++--- 3 files changed, 37 insertions(+), 25 deletions(-) diff --git a/lib/pages/video/detail/view.dart b/lib/pages/video/detail/view.dart index a0f5d6bc..a99ee936 100644 --- a/lib/pages/video/detail/view.dart +++ b/lib/pages/video/detail/view.dart @@ -591,27 +591,32 @@ class _VideoDetailPageState extends State verticalScreen(); } }, - child: Hero( - tag: heroTag, - child: Stack( - children: [ - if (isShowing) videoPlayerPanel, + child: LayoutBuilder( + builder: (BuildContext context, + BoxConstraints constraints) { + return Hero( + tag: heroTag, + child: Stack( + children: [ + if (isShowing) videoPlayerPanel, - /// 关闭自动播放时 手动播放 - Obx( - () => Visibility( - visible: !vdCtr.autoPlay.value && - vdCtr.isShowCover.value, - child: Positioned( - top: 0, - left: 0, - right: 0, - child: handlePlayPanel(), + /// 关闭自动播放时 手动播放 + Obx( + () => Visibility( + visible: !vdCtr.autoPlay.value && + vdCtr.isShowCover.value, + child: Positioned( + top: 0, + left: 0, + right: 0, + child: handlePlayPanel(), + ), + ), ), - ), + ], ), - ], - ), + ); + }, ), ), ), diff --git a/lib/pages/video/detail/widgets/header_control.dart b/lib/pages/video/detail/widgets/header_control.dart index d839a1eb..b597a060 100644 --- a/lib/pages/video/detail/widgets/header_control.dart +++ b/lib/pages/video/detail/widgets/header_control.dart @@ -1069,7 +1069,9 @@ class _HeaderControlState extends State { ); }); }, - ); + ).then((value) { + widget.controller!.cacheDanmakuOption(); + }); } /// 播放顺序 diff --git a/lib/plugin/pl_player/controller.dart b/lib/plugin/pl_player/controller.dart index 03c2efbe..2865a117 100644 --- a/lib/plugin/pl_player/controller.dart +++ b/lib/plugin/pl_player/controller.dart @@ -1089,6 +1089,16 @@ class PlPlayerController { videoStorage.put(VideoBoxKey.playRepeat, type.value); } + /// 缓存本次弹幕选项 + cacheDanmakuOption() { + localCache.put(LocalCacheKey.danmakuBlockType, blockTypes); + localCache.put(LocalCacheKey.danmakuShowArea, showArea); + localCache.put(LocalCacheKey.danmakuOpacity, opacityVal); + localCache.put(LocalCacheKey.danmakuFontScale, fontSizeVal); + localCache.put(LocalCacheKey.danmakuDuration, danmakuDurationVal); + localCache.put(LocalCacheKey.strokeWidth, strokeWidth); + } + Future dispose({String type = 'single'}) async { // 每次减1,最后销毁 if (type == 'single' && playerCount.value > 1) { @@ -1118,12 +1128,7 @@ class PlPlayerController { // dataStatus.status.close(); /// 缓存本次弹幕选项 - localCache.put(LocalCacheKey.danmakuBlockType, blockTypes); - localCache.put(LocalCacheKey.danmakuShowArea, showArea); - localCache.put(LocalCacheKey.danmakuOpacity, opacityVal); - localCache.put(LocalCacheKey.danmakuFontScale, fontSizeVal); - localCache.put(LocalCacheKey.danmakuDuration, danmakuDurationVal); - localCache.put(LocalCacheKey.strokeWidth, strokeWidth); + cacheDanmakuOption(); if (_videoPlayerController != null) { var pp = _videoPlayerController!.platform as NativePlayer; await pp.setProperty('audio-files', ''); From 5c3d3cc957e037a699a7f8a19a32c375227d35f5 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Wed, 12 Jun 2024 23:37:29 +0800 Subject: [PATCH 5/5] undo: flutter version 3.22.1 -> 3.19.1 --- lib/common/widgets/http_error.dart | 2 +- lib/common/widgets/video_card_h.dart | 2 +- lib/pages/bangumi/introduction/view.dart | 8 ++--- lib/pages/bangumi/widgets/bangumi_panel.dart | 2 +- lib/pages/dynamics/view.dart | 2 +- lib/pages/dynamics/widgets/author_panel.dart | 2 +- .../fav_detail/widget/fav_video_card.dart | 2 +- lib/pages/history/widgets/item.dart | 5 +-- lib/pages/home/view.dart | 8 ++--- .../live_room/widgets/bottom_control.dart | 2 +- lib/pages/login/view.dart | 6 ++-- lib/pages/media/view.dart | 4 +-- lib/pages/search/widgets/search_text.dart | 5 +-- .../search_panel/widgets/video_panel.dart | 2 +- lib/pages/setting/extra_setting.dart | 6 ++-- lib/pages/setting/style_setting.dart | 6 ++-- lib/pages/setting/widgets/switch_item.dart | 6 ++-- lib/pages/subscription/widgets/item.dart | 2 +- .../introduction/widgets/page_panel.dart | 2 +- .../detail/reply_new/toolbar_icon_button.dart | 4 +-- lib/pages/video/detail/reply_new/view.dart | 2 +- lib/pages/video/detail/view.dart | 2 +- .../video/detail/widgets/header_control.dart | 8 ++--- lib/pages/whisper_detail/view.dart | 6 ++-- lib/plugin/pl_player/view.dart | 6 ++-- lib/plugin/pl_player/widgets/common_btn.dart | 2 +- .../pl_player/widgets/play_pause_btn.dart | 2 +- lib/utils/image_save.dart | 2 +- pubspec.lock | 36 +++++++++---------- 29 files changed, 72 insertions(+), 72 deletions(-) diff --git a/lib/common/widgets/http_error.dart b/lib/common/widgets/http_error.dart index b130faae..cbc6659b 100644 --- a/lib/common/widgets/http_error.dart +++ b/lib/common/widgets/http_error.dart @@ -34,7 +34,7 @@ class HttpError extends StatelessWidget { fn!(); }, style: ButtonStyle( - backgroundColor: WidgetStateProperty.resolveWith((states) { + backgroundColor: MaterialStateProperty.resolveWith((states) { return Theme.of(context).colorScheme.primary.withAlpha(20); }), ), diff --git a/lib/common/widgets/video_card_h.dart b/lib/common/widgets/video_card_h.dart index c674b223..1265477f 100644 --- a/lib/common/widgets/video_card_h.dart +++ b/lib/common/widgets/video_card_h.dart @@ -305,7 +305,7 @@ class VideoContent extends StatelessWidget { if (source == 'later') ...[ IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () => onPressedFn?.call(), icon: Icon( diff --git a/lib/pages/bangumi/introduction/view.dart b/lib/pages/bangumi/introduction/view.dart index bb85be1a..95d4d898 100644 --- a/lib/pages/bangumi/introduction/view.dart +++ b/lib/pages/bangumi/introduction/view.dart @@ -232,11 +232,11 @@ class _BangumiInfoState extends State { height: 34, child: IconButton( style: ButtonStyle( - padding: - WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all( + EdgeInsets.zero), backgroundColor: - WidgetStateProperty.resolveWith( - (Set states) { + MaterialStateProperty.resolveWith( + (Set states) { return t.colorScheme.primaryContainer .withOpacity(0.7); }), diff --git a/lib/pages/bangumi/widgets/bangumi_panel.dart b/lib/pages/bangumi/widgets/bangumi_panel.dart index 345a47b6..3df7ce25 100644 --- a/lib/pages/bangumi/widgets/bangumi_panel.dart +++ b/lib/pages/bangumi/widgets/bangumi_panel.dart @@ -139,7 +139,7 @@ class _BangumiPanelState extends State { height: 34, child: TextButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () { widget.bangumiIntroController?.bottomSheetController = diff --git a/lib/pages/dynamics/view.dart b/lib/pages/dynamics/view.dart index 258ad531..1775798e 100644 --- a/lib/pages/dynamics/view.dart +++ b/lib/pages/dynamics/view.dart @@ -162,7 +162,7 @@ class _DynamicsPageState extends State decoration: BoxDecoration( color: Theme.of(context) .colorScheme - .surfaceContainerHighest + .surfaceVariant .withOpacity(0.7), borderRadius: BorderRadius.circular(20), ), diff --git a/lib/pages/dynamics/widgets/author_panel.dart b/lib/pages/dynamics/widgets/author_panel.dart index e66e2a91..8acdc26a 100644 --- a/lib/pages/dynamics/widgets/author_panel.dart +++ b/lib/pages/dynamics/widgets/author_panel.dart @@ -82,7 +82,7 @@ class AuthorPanel extends StatelessWidget { height: 32, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () { showModalBottomSheet( diff --git a/lib/pages/fav_detail/widget/fav_video_card.dart b/lib/pages/fav_detail/widget/fav_video_card.dart index 72d7b4a0..79e5c073 100644 --- a/lib/pages/fav_detail/widget/fav_video_card.dart +++ b/lib/pages/fav_detail/widget/fav_video_card.dart @@ -217,7 +217,7 @@ class VideoContent extends StatelessWidget { bottom: -4, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () { showDialog( diff --git a/lib/pages/history/widgets/item.dart b/lib/pages/history/widgets/item.dart index 8e71df6f..baebfedb 100644 --- a/lib/pages/history/widgets/item.dart +++ b/lib/pages/history/widgets/item.dart @@ -217,10 +217,11 @@ class HistoryItem extends StatelessWidget { curve: Curves.easeInOut, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all( + padding: MaterialStateProperty.all( EdgeInsets.zero), backgroundColor: - WidgetStateProperty.resolveWith( + MaterialStateProperty + .resolveWith( (states) { return Colors.white .withOpacity(0.8); diff --git a/lib/pages/home/view.dart b/lib/pages/home/view.dart index 0c45a262..a25389bd 100644 --- a/lib/pages/home/view.dart +++ b/lib/pages/home/view.dart @@ -278,8 +278,8 @@ class DefaultUser extends StatelessWidget { height: 38, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), - backgroundColor: WidgetStateProperty.resolveWith((states) { + padding: MaterialStateProperty.all(EdgeInsets.zero), + backgroundColor: MaterialStateProperty.resolveWith((states) { return Theme.of(context).colorScheme.onInverseSurface; }), ), @@ -371,8 +371,8 @@ class CustomChip extends StatelessWidget { ), backgroundColor: secondaryContainer, selectedColor: secondaryContainer, - color: WidgetStateProperty.resolveWith( - (Set states) => secondaryContainer.withAlpha(200)), + color: MaterialStateProperty.resolveWith( + (Set states) => secondaryContainer.withAlpha(200)), padding: const EdgeInsets.fromLTRB(7, 1, 7, 1), label: Text(label, style: chipTextStyle), onPressed: () => onTap(), diff --git a/lib/pages/live_room/widgets/bottom_control.dart b/lib/pages/live_room/widgets/bottom_control.dart index 6abb1260..4dd7c538 100644 --- a/lib/pages/live_room/widgets/bottom_control.dart +++ b/lib/pages/live_room/widgets/bottom_control.dart @@ -124,7 +124,7 @@ class _BottomControlState extends State { height: 34, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () async { bool canUsePiP = false; diff --git a/lib/pages/login/view.dart b/lib/pages/login/view.dart index 04d5a1a8..85a8adf0 100644 --- a/lib/pages/login/view.dart +++ b/lib/pages/login/view.dart @@ -249,7 +249,8 @@ class _LoginPageState extends State { IconButton( style: ButtonStyle( backgroundColor: - WidgetStateProperty.resolveWith((states) { + MaterialStateProperty.resolveWith( + (states) { return Theme.of(context) .colorScheme .primary @@ -339,7 +340,8 @@ class _LoginPageState extends State { IconButton( style: ButtonStyle( backgroundColor: - WidgetStateProperty.resolveWith((states) { + MaterialStateProperty.resolveWith( + (states) { return Theme.of(context) .colorScheme .primary diff --git a/lib/pages/media/view.dart b/lib/pages/media/view.dart index f6a033e5..cc413e59 100644 --- a/lib/pages/media/view.dart +++ b/lib/pages/media/view.dart @@ -178,10 +178,10 @@ class _MediaPageState extends State child: Center( child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all( + padding: MaterialStateProperty.all( EdgeInsets.zero), backgroundColor: - WidgetStateProperty.resolveWith( + MaterialStateProperty.resolveWith( (states) { return Theme.of(context) .colorScheme diff --git a/lib/pages/search/widgets/search_text.dart b/lib/pages/search/widgets/search_text.dart index d3ffafea..bcc8c17e 100644 --- a/lib/pages/search/widgets/search_text.dart +++ b/lib/pages/search/widgets/search_text.dart @@ -20,10 +20,7 @@ class SearchText extends StatelessWidget { return Material( color: isSelect ? Theme.of(context).colorScheme.primaryContainer - : Theme.of(context) - .colorScheme - .surfaceContainerHighest - .withOpacity(0.5), + : Theme.of(context).colorScheme.surfaceVariant.withOpacity(0.5), borderRadius: BorderRadius.circular(6), child: Padding( padding: EdgeInsets.zero, diff --git a/lib/pages/search_panel/widgets/video_panel.dart b/lib/pages/search_panel/widgets/video_panel.dart index bc9b48c9..15745bde 100644 --- a/lib/pages/search_panel/widgets/video_panel.dart +++ b/lib/pages/search_panel/widgets/video_panel.dart @@ -93,7 +93,7 @@ class SearchVideoPanel extends StatelessWidget { height: 32, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () => controller.onShowFilterSheet(ctr), icon: Icon( diff --git a/lib/pages/setting/extra_setting.dart b/lib/pages/setting/extra_setting.dart index 885a831c..aaaa8b84 100644 --- a/lib/pages/setting/extra_setting.dart +++ b/lib/pages/setting/extra_setting.dart @@ -240,10 +240,10 @@ class _ExtraSettingState extends State { alignment: Alignment.centerRight, scale: 0.8, child: Switch( - thumbIcon: WidgetStateProperty.resolveWith( - (Set states) { + thumbIcon: MaterialStateProperty.resolveWith( + (Set states) { if (states.isNotEmpty && - states.first == WidgetState.selected) { + states.first == MaterialState.selected) { return const Icon(Icons.done); } return null; // All other states will use the default thumbIcon. diff --git a/lib/pages/setting/style_setting.dart b/lib/pages/setting/style_setting.dart index b6ee5041..5fca0c86 100644 --- a/lib/pages/setting/style_setting.dart +++ b/lib/pages/setting/style_setting.dart @@ -69,10 +69,10 @@ class _StyleSettingState extends State { alignment: Alignment.centerRight, scale: 0.8, child: Switch( - thumbIcon: WidgetStateProperty.resolveWith( - (Set states) { + thumbIcon: MaterialStateProperty.resolveWith( + (Set states) { if (states.isNotEmpty && - states.first == WidgetState.selected) { + states.first == MaterialState.selected) { return const Icon(Icons.done); } return null; // All other states will use the default thumbIcon. diff --git a/lib/pages/setting/widgets/switch_item.dart b/lib/pages/setting/widgets/switch_item.dart index 36c4433e..d0c2bbf2 100644 --- a/lib/pages/setting/widgets/switch_item.dart +++ b/lib/pages/setting/widgets/switch_item.dart @@ -70,9 +70,9 @@ class _SetSwitchItemState extends State { alignment: Alignment.centerRight, // 缩放Switch的大小后保持右侧对齐, 避免右侧空隙过大 scale: 0.8, child: Switch( - thumbIcon: - WidgetStateProperty.resolveWith((Set states) { - if (states.isNotEmpty && states.first == WidgetState.selected) { + thumbIcon: MaterialStateProperty.resolveWith( + (Set states) { + if (states.isNotEmpty && states.first == MaterialState.selected) { return const Icon(Icons.done); } return null; // All other states will use the default thumbIcon. diff --git a/lib/pages/subscription/widgets/item.dart b/lib/pages/subscription/widgets/item.dart index 6c1cc2b9..b244d3c7 100644 --- a/lib/pages/subscription/widgets/item.dart +++ b/lib/pages/subscription/widgets/item.dart @@ -116,7 +116,7 @@ class VideoContent extends StatelessWidget { children: [ IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () => cancelSub?.call(subFolderItem), icon: Icon( diff --git a/lib/pages/video/detail/introduction/widgets/page_panel.dart b/lib/pages/video/detail/introduction/widgets/page_panel.dart index c8111847..266f5566 100644 --- a/lib/pages/video/detail/introduction/widgets/page_panel.dart +++ b/lib/pages/video/detail/introduction/widgets/page_panel.dart @@ -106,7 +106,7 @@ class _PagesPanelState extends State { height: 34, child: TextButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () { widget.videoIntroCtr.bottomSheetController = diff --git a/lib/pages/video/detail/reply_new/toolbar_icon_button.dart b/lib/pages/video/detail/reply_new/toolbar_icon_button.dart index bf810ce2..c4390796 100644 --- a/lib/pages/video/detail/reply_new/toolbar_icon_button.dart +++ b/lib/pages/video/detail/reply_new/toolbar_icon_button.dart @@ -27,8 +27,8 @@ class ToolbarIconButton extends StatelessWidget { ? Theme.of(context).colorScheme.onSecondaryContainer : Theme.of(context).colorScheme.outline, style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), - backgroundColor: WidgetStateProperty.resolveWith((states) { + padding: MaterialStateProperty.all(EdgeInsets.zero), + backgroundColor: MaterialStateProperty.resolveWith((states) { return selected ? Theme.of(context).colorScheme.secondaryContainer : null; diff --git a/lib/pages/video/detail/reply_new/view.dart b/lib/pages/video/detail/reply_new/view.dart index d55e2c1c..40267559 100644 --- a/lib/pages/video/detail/reply_new/view.dart +++ b/lib/pages/video/detail/reply_new/view.dart @@ -267,7 +267,7 @@ class _VideoReplyNewDialogState extends State size: 22), label: const Text('转发到动态'), style: ButtonStyle( - foregroundColor: WidgetStateProperty.all( + foregroundColor: MaterialStateProperty.all( isForward.value ? Theme.of(context).colorScheme.primary : Theme.of(context).colorScheme.outline, diff --git a/lib/pages/video/detail/view.dart b/lib/pages/video/detail/view.dart index a99ee936..22271c2b 100644 --- a/lib/pages/video/detail/view.dart +++ b/lib/pages/video/detail/view.dart @@ -412,7 +412,7 @@ class _VideoDetailPageState extends State height: 32, child: TextButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () => vdCtr.showShootDanmakuSheet(), child: diff --git a/lib/pages/video/detail/widgets/header_control.dart b/lib/pages/video/detail/widgets/header_control.dart index b597a060..f51edff1 100644 --- a/lib/pages/video/detail/widgets/header_control.dart +++ b/lib/pages/video/detail/widgets/header_control.dart @@ -1250,7 +1250,7 @@ class _HeaderControlState extends State { height: 34, child: TextButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () => showShootDanmakuSheet(), child: const Text( @@ -1265,7 +1265,7 @@ class _HeaderControlState extends State { child: Obx( () => IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () { _.isOpenDanmu.value = !_.isOpenDanmu.value; @@ -1288,7 +1288,7 @@ class _HeaderControlState extends State { height: 34, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () async { bool canUsePiP = false; @@ -1332,7 +1332,7 @@ class _HeaderControlState extends State { height: 34, child: TextButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () => showSetSpeedSheet(), child: Text( diff --git a/lib/pages/whisper_detail/view.dart b/lib/pages/whisper_detail/view.dart index 042afca1..1701be33 100644 --- a/lib/pages/whisper_detail/view.dart +++ b/lib/pages/whisper_detail/view.dart @@ -95,9 +95,9 @@ class _WhisperDetailPageState extends State height: 34, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), - backgroundColor: WidgetStateProperty.resolveWith( - (Set states) { + padding: MaterialStateProperty.all(EdgeInsets.zero), + backgroundColor: MaterialStateProperty.resolveWith( + (Set states) { return Theme.of(context) .colorScheme .primaryContainer diff --git a/lib/plugin/pl_player/view.dart b/lib/plugin/pl_player/view.dart index 0e405884..34140be8 100644 --- a/lib/plugin/pl_player/view.dart +++ b/lib/plugin/pl_player/view.dart @@ -279,7 +279,7 @@ class _PLVideoPlayerState extends State widget.showEposideCb?.call(); }, style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), child: const Text( '选集', @@ -294,7 +294,7 @@ class _PLVideoPlayerState extends State child: TextButton( onPressed: () => _.toggleVideoFit(), style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), child: Obx( () => Text( @@ -311,7 +311,7 @@ class _PLVideoPlayerState extends State height: 34, child: TextButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () {}, child: Obx( diff --git a/lib/plugin/pl_player/widgets/common_btn.dart b/lib/plugin/pl_player/widgets/common_btn.dart index bf9467a8..5f33311c 100644 --- a/lib/plugin/pl_player/widgets/common_btn.dart +++ b/lib/plugin/pl_player/widgets/common_btn.dart @@ -17,7 +17,7 @@ class ComBtn extends StatelessWidget { height: 34, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () { fuc!(); diff --git a/lib/plugin/pl_player/widgets/play_pause_btn.dart b/lib/plugin/pl_player/widgets/play_pause_btn.dart index 7547a1cb..6cbe31f0 100644 --- a/lib/plugin/pl_player/widgets/play_pause_btn.dart +++ b/lib/plugin/pl_player/widgets/play_pause_btn.dart @@ -68,7 +68,7 @@ class PlayOrPauseButtonState extends State height: 34, child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: player.playOrPause, color: Colors.white, diff --git a/lib/utils/image_save.dart b/lib/utils/image_save.dart index 0727ad68..0b77b7cc 100644 --- a/lib/utils/image_save.dart +++ b/lib/utils/image_save.dart @@ -39,7 +39,7 @@ Future imageSaveDialog(context, videoItem, closeFn) { const BorderRadius.all(Radius.circular(20))), child: IconButton( style: ButtonStyle( - padding: WidgetStateProperty.all(EdgeInsets.zero), + padding: MaterialStateProperty.all(EdgeInsets.zero), ), onPressed: () => closeFn!(), icon: const Icon( diff --git a/pubspec.lock b/pubspec.lock index 5c6f2b43..c73ce395 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -762,10 +762,10 @@ packages: dependency: transitive description: name: intl - sha256: d6f56758b7d3014a48af9701c085700aac781a92a87a62b1333b46d8879661cf + sha256: "3bc132a9dbce73a7e4a21a17d06e1878839ffbf975568bc875c60537824b0c4d" url: "https://pub.flutter-io.cn" source: hosted - version: "0.19.0" + version: "0.18.1" io: dependency: transitive description: @@ -794,26 +794,26 @@ packages: dependency: transitive description: name: leak_tracker - sha256: "7f0df31977cb2c0b88585095d168e689669a2cc9b97c309665e3386f3e9d341a" + sha256: "78eb209deea09858f5269f5a5b02be4049535f568c07b275096836f01ea323fa" url: "https://pub.flutter-io.cn" source: hosted - version: "10.0.4" + version: "10.0.0" leak_tracker_flutter_testing: dependency: transitive description: name: leak_tracker_flutter_testing - sha256: "06e98f569d004c1315b991ded39924b21af84cf14cc94791b8aea337d25b57f8" + sha256: b46c5e37c19120a8a01918cfaf293547f47269f7cb4b0058f21531c2465d6ef0 url: "https://pub.flutter-io.cn" source: hosted - version: "3.0.3" + version: "2.0.1" leak_tracker_testing: dependency: transitive description: name: leak_tracker_testing - sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3" + sha256: a597f72a664dbd293f3bfc51f9ba69816f84dcd403cdac7066cb3f6003f3ab47 url: "https://pub.flutter-io.cn" source: hosted - version: "3.0.1" + version: "2.0.1" lints: dependency: transitive description: @@ -973,10 +973,10 @@ packages: dependency: transitive description: name: meta - sha256: "7687075e408b093f36e6bbf6c91878cc0d4cd10f409506f7bc996f68220b9136" + sha256: d584fa6707a52763a52446f02cc621b077888fb63b93bbcb1143a7be5a0c0c04 url: "https://pub.flutter-io.cn" source: hosted - version: "1.12.0" + version: "1.11.0" mime: dependency: transitive description: @@ -1467,10 +1467,10 @@ packages: dependency: transitive description: name: test_api - sha256: "9955ae474176f7ac8ee4e989dadfb411a58c30415bcfb648fa04b2b8a03afa7f" + sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" url: "https://pub.flutter-io.cn" source: hosted - version: "0.7.0" + version: "0.6.1" timing: dependency: transitive description: @@ -1627,10 +1627,10 @@ packages: dependency: transitive description: name: vm_service - sha256: "3923c89304b715fb1eb6423f017651664a03bf5f4b29983627c4da791f74a4ec" + sha256: b3d56ff4341b8f182b96aceb2fa20e3dcb336b9f867bc0eafc0de10f1048e957 url: "https://pub.flutter-io.cn" source: hosted - version: "14.2.1" + version: "13.0.0" volume_controller: dependency: transitive description: @@ -1707,10 +1707,10 @@ packages: dependency: transitive description: name: webview_flutter_android - sha256: f42447ca49523f11d8f70abea55ea211b3cafe172dd7a0e7ac007bb35dd356dc + sha256: "0d21cfc3bfdd2e30ab2ebeced66512b91134b39e72e97b43db2d47dda1c4e53a" url: "https://pub.flutter-io.cn" source: hosted - version: "3.16.4" + version: "3.16.3" webview_flutter_platform_interface: dependency: transitive description: @@ -1768,5 +1768,5 @@ packages: source: hosted version: "3.1.2" sdks: - dart: ">=3.4.0 <4.0.0" - flutter: ">=3.22.0" + dart: ">=3.3.0 <4.0.0" + flutter: ">=3.19.0"