From 10b928474bfc96ccc32fd33d0a6b3b1ad5c1eea6 Mon Sep 17 00:00:00 2001 From: guozhigq Date: Thu, 8 Feb 2024 22:46:39 +0800 Subject: [PATCH] mod --- lib/pages/live/widgets/live_item.dart | 36 ++++++++++++------ lib/pages/live_room/view.dart | 55 +++++++++++++++++---------- 2 files changed, 59 insertions(+), 32 deletions(-) diff --git a/lib/pages/live/widgets/live_item.dart b/lib/pages/live/widgets/live_item.dart index 8fa797fb..9218d4fb 100644 --- a/lib/pages/live/widgets/live_item.dart +++ b/lib/pages/live/widgets/live_item.dart @@ -184,18 +184,32 @@ class VideoStat extends StatelessWidget { tileMode: TileMode.mirror, ), ), - child: RichText( - maxLines: 1, - textAlign: TextAlign.justify, - softWrap: false, - text: TextSpan( - style: const TextStyle(fontSize: 11, color: Colors.white), - children: [ - TextSpan(text: liveItem!.areaName!), - TextSpan(text: liveItem!.watchedShow!['text_small']), - ], - ), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + Text( + liveItem!.areaName!, + style: const TextStyle(fontSize: 11, color: Colors.white), + ), + Text( + liveItem!.watchedShow!['text_small'], + style: const TextStyle(fontSize: 11, color: Colors.white), + ), + ], ), + + // child: RichText( + // maxLines: 1, + // textAlign: TextAlign.justify, + // softWrap: false, + // text: TextSpan( + // style: const TextStyle(fontSize: 11, color: Colors.white), + // children: [ + // TextSpan(text: liveItem!.areaName!), + // TextSpan(text: liveItem!.watchedShow!['text_small']), + // ], + // ), + // ), ); } } diff --git a/lib/pages/live_room/view.dart b/lib/pages/live_room/view.dart index f727bfd0..20dfe403 100644 --- a/lib/pages/live_room/view.dart +++ b/lib/pages/live_room/view.dart @@ -79,27 +79,40 @@ class _LiveRoomPageState extends State { backgroundColor: Colors.black, body: Stack( children: [ - Obx( - () => - _liveRoomController.roomInfoH5.value.roomInfo?.appBackground != - '' - ? Positioned.fill( - child: Opacity( - opacity: 0.8, - child: NetworkImgLayer( - width: Get.width, - height: Get.height, - src: _liveRoomController - .roomInfoH5.value.roomInfo?.appBackground ?? - '', - ), - ), - ) - : Image.asset( - 'assets/images/live/default_bg.webp', - width: Get.width, - height: Get.height, - ), + // Obx( + // () => Positioned.fill( + // child: Opacity( + // opacity: 0.8, + // child: _liveRoomController + // .roomInfoH5.value.roomInfo?.appBackground != + // '' && + // _liveRoomController + // .roomInfoH5.value.roomInfo?.appBackground != + // null + // ? NetworkImgLayer( + // width: Get.width, + // height: Get.height, + // src: _liveRoomController + // .roomInfoH5.value.roomInfo?.appBackground ?? + // '', + // ) + // : Image.asset( + // 'assets/images/live/default_bg.webp', + // width: Get.width, + // height: Get.height, + // ), + // ), + // ), + // ), + Positioned.fill( + child: Opacity( + opacity: 0.8, + child: Image.asset( + 'assets/images/live/default_bg.webp', + width: Get.width, + height: Get.height, + ), + ), ), Column( children: [