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,