diff --git a/assets/images/login_warning.png b/assets/images/login_warning.png new file mode 100644 index 0000000..ee324e6 Binary files /dev/null and b/assets/images/login_warning.png differ diff --git a/lib/components/home_appbar.dart b/lib/components/home_appbar.dart index 3fcc19f..1d50b37 100644 --- a/lib/components/home_appbar.dart +++ b/lib/components/home_appbar.dart @@ -62,6 +62,7 @@ class _HomeAppbarState extends State { ), SizedBox(height: ScreenUtil().setWidth(4),), if(currentActive == entry.key) Image.asset( + gaplessPlayback: true, Assets.imagesTabChangeIcon, width: 20, ) diff --git a/lib/controller/discover/search_page_controller.dart b/lib/controller/discover/search_page_controller.dart index b973046..968802e 100644 --- a/lib/controller/discover/search_page_controller.dart +++ b/lib/controller/discover/search_page_controller.dart @@ -36,6 +36,9 @@ class SearchPageController extends GetxController { } searchData() async { + if(name.value.trim() == "" || name.value.trim().isEmpty){ + return; + } try{ final response = await _networkService.rtcApi.userPageLiveMatchmaker( diff --git a/lib/controller/message/conversation_controller.dart b/lib/controller/message/conversation_controller.dart index 7f2fe00..a37ac83 100644 --- a/lib/controller/message/conversation_controller.dart +++ b/lib/controller/message/conversation_controller.dart @@ -73,6 +73,7 @@ class ConversationController extends GetxController { final name = "".obs; final showSearch = false.obs; + final isSearch = false.obs; @@ -81,6 +82,7 @@ class ConversationController extends GetxController { } search(){ + isSearch.value = true; if(name.value == ""){ _checkAndLoadConversations(); } else { diff --git a/lib/controller/mine/user_controller.dart b/lib/controller/mine/user_controller.dart index 786a1c5..e9b91be 100644 --- a/lib/controller/mine/user_controller.dart +++ b/lib/controller/mine/user_controller.dart @@ -1,5 +1,13 @@ +import 'package:dating_touchme_app/controller/discover/room_controller.dart'; +import 'package:dating_touchme_app/controller/message/conversation_controller.dart'; +import 'package:dating_touchme_app/controller/overlay_controller.dart'; +import 'package:dating_touchme_app/extension/ex_widget.dart'; +import 'package:dating_touchme_app/generated/assets.dart'; import 'package:dating_touchme_app/im/im_manager.dart'; import 'package:dating_touchme_app/oss/oss_manager.dart'; +import 'package:dating_touchme_app/pages/mine/login_page.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_screenutil/flutter_screenutil.dart'; import 'package:get/get.dart'; import 'package:flutter_smart_dialog/flutter_smart_dialog.dart'; import 'package:get_storage/get_storage.dart'; @@ -85,6 +93,57 @@ class UserController extends GetxController { return false; } + + + void logout() async { + // 退出直播间 + if (Get.isRegistered()) { + try { + final roomController = Get.find(); + await roomController.leaveChannel(); + } catch (e) { + print('退出直播间失败: $e'); + } + } + + // 取消小窗口 + if (Get.isRegistered()) { + try { + final overlayController = Get.find(); + overlayController.hide(); // 隐藏直播房间小窗 + overlayController.hideVideoCall(); // 隐藏视频通话小窗 + } catch (e) { + print('取消小窗口失败: $e'); + } + } + + // 先退出 IM 登录 + if(IMManager.instance.isInitialized){ + await IMManager.instance.logout(); + } + // 清除会话列表和用户信息缓存 + if (Get.isRegistered()) { + final conversationController = Get.find(); + conversationController.clearConversations(); + } + // App清除本地存储,有待处理, + // storage.erase(); + storage.remove('userId'); + storage.remove('token'); + // storage.write('hasAgreedUserAgreement', true); + // 清除全局数据 + GlobalData().logout(); + Get.offAll(() => LoginPage()); + } + + static const statusMap = { + 1: '3天', + 2: '7天', + 3: '15天', + 4: '30天', + 5: '永久', + }; + /// 获取用户基础信息 Future getBaseUserInfo(String userId, bool isMain) async { try { @@ -93,6 +152,100 @@ class UserController extends GetxController { if (response.data.isSuccess && response.data.data != null) { // 成功获取基础信息后,调用获取婚姻信息详情接口 final baseInfo = response.data.data!; + if(baseInfo.isForbidden == true){ + + final storage = GetStorage(); + final userId = storage.read('userId'); + if (userId != null && userId.isNotEmpty) { + + logout(); + } + SmartDialog.dismiss(); + + + + SmartDialog.show( + onDismiss: (){ + SmartDialog.dismiss(); + }, + builder: (context) { + return ClipRRect( + borderRadius: BorderRadius.all(Radius.circular(16.w)), + child: Material( + color: Colors.white, + child: Container( + width: 311.w, + height: 256.w, + padding: EdgeInsets.only( + top: 18.w, + right: 19.w, + left: 19.w + ), + decoration: BoxDecoration( + gradient: LinearGradient( + begin: Alignment.topCenter, + end: Alignment.bottomCenter, + colors: [ + Color(0xFFFFFFFF), + Color(0xFFF4F2FF), + ], + ), + ), + child: Column( + children: [ + Image.asset( + Assets.imagesLoginWarning, + width: 44.w, + height: 44.w, + ), + SizedBox(height: 4.w,), + Text( + "账号已限制登录", + textAlign: TextAlign.center, + style: TextStyle( + fontSize: 16.w + ), + ), + SizedBox(height: 10.w,), + Text( + "你的账号涉嫌违规已被系统封禁,如需申诉,请点击右上角联系客服进行反馈。\n" + "封禁时间:${statusMap[baseInfo.forbiddenCycle] ?? "未知"}\n" + "${baseInfo.forbiddenCycle != 5 ? "解除时间:${baseInfo.forbiddenEndTime}" : ""}", + style: TextStyle( + fontSize: 13.w + ), + ), + SizedBox(height: 12.w,), + Container( + width: 128.w, + height: 40.w, + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(12.w)), + color: const Color.fromRGBO(117, 98, 249, 1) + ), + child: Center( + child: Text( + "知道了", + style: TextStyle( + fontSize: 14.w, + color: Colors.white + ), + ), + ), + ).onTap(() { + + // 隐藏 overlay + SmartDialog.dismiss(); + }) + ], + ), + ), + ), + ); + }, + ); + return ; + } final result = await _userApi.getMarriageInformationDetail(); // print(result.data); if (result.data.isSuccess) { diff --git a/lib/generated/assets.dart b/lib/generated/assets.dart index 5cc4e57..95b4ff7 100644 --- a/lib/generated/assets.dart +++ b/lib/generated/assets.dart @@ -146,6 +146,7 @@ class Assets { static const String imagesLocationIcon = 'assets/images/location_icon.png'; static const String imagesLoginBg = 'assets/images/login_bg.png'; static const String imagesLoginLogo = 'assets/images/login_logo.png'; + static const String imagesLoginWarning = 'assets/images/login_warning.png'; static const String imagesMail = 'assets/images/mail.png'; static const String imagesMale = 'assets/images/male.png'; static const String imagesMaleEmpty = 'assets/images/male_empty.png'; diff --git a/lib/model/mine/user_base_data.dart b/lib/model/mine/user_base_data.dart index ccf2071..c862808 100644 --- a/lib/model/mine/user_base_data.dart +++ b/lib/model/mine/user_base_data.dart @@ -50,6 +50,9 @@ class UserBaseData { final LiveMatchmaker? liveMatchmaker; final int matchmakerType; final bool? isOnline; // 在线状态 + final bool? isForbidden; + final String? forbiddenEndTime; + final int forbiddenCycle; UserBaseData({ @@ -62,6 +65,9 @@ class UserBaseData { required this.matchmakerType, this.liveMatchmaker, this.isOnline, + this.isForbidden, + required this.forbiddenEndTime, + required this.forbiddenCycle, }); // 从JSON映射创建实例 @@ -76,6 +82,9 @@ class UserBaseData { userId: json['userId'] ?? '', liveMatchmaker: json['liveMatchmaker'] != null ? LiveMatchmaker.fromJson(json['liveMatchmaker'] as Map) : null, isOnline: json['isOnline'] as bool?, + isForbidden: json['isForbidden'] as bool?, + forbiddenCycle: json['forbiddenCycle'] ?? 0, + forbiddenEndTime: json['forbiddenEndTime'] ?? '', ); } @@ -91,6 +100,9 @@ class UserBaseData { 'userId': userId, 'liveMatchmaker': liveMatchmaker?.toJson(), 'isOnline': isOnline, + 'isForbidden': isForbidden, + 'forbiddenCycle': forbiddenCycle, + 'forbiddenEndTime': forbiddenEndTime, }; } diff --git a/lib/pages/discover/discover_page.dart b/lib/pages/discover/discover_page.dart index 3c7b04b..9ebae75 100644 --- a/lib/pages/discover/discover_page.dart +++ b/lib/pages/discover/discover_page.dart @@ -65,7 +65,11 @@ class _DiscoverPageState extends State super.build(context); return Stack( children: [ + Positioned.fill( + child: Container(color: Colors.white,), + ), Image.asset( + gaplessPlayback: true, Assets.imagesBgInformation, fit: BoxFit.cover, width: double.infinity, @@ -84,9 +88,30 @@ class _DiscoverPageState extends State right: Row( children: [ - Icon( - Icons.search, - size: 30, + Container( + width: 60.w, + height: 27.w, + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(27.w)), + color: const Color.fromRGBO(0, 0, 0, .2) + ), + child: Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Icon( + Icons.search, + size: 15.w, + color: Colors.white, + ), + Text( + "搜索", + style: TextStyle( + fontSize: 12.w, + color: Colors.white + ), + ) + ], + ), ).onTap((){ Get.to(() => SearchPage()); }), diff --git a/lib/pages/discover/search_page.dart b/lib/pages/discover/search_page.dart index 7f74ee7..b60d78d 100644 --- a/lib/pages/discover/search_page.dart +++ b/lib/pages/discover/search_page.dart @@ -31,18 +31,18 @@ class SearchPage extends StatelessWidget { padding: EdgeInsets.symmetric(horizontal: 15.w), margin: EdgeInsets.only(bottom: 10.w), child: Container( - height: 30.w, + height: 45.w, padding: EdgeInsets.symmetric(horizontal: 10), decoration: BoxDecoration( - borderRadius: BorderRadius.all(Radius.circular(30.w)), - color: const Color.fromRGBO(200, 200, 200, 1.0) + borderRadius: BorderRadius.all(Radius.circular(9.w)), + color: const Color.fromRGBO(247, 247, 247, 1.0) ), child: Row( children: [ Icon( Icons.search, size: 20, - color: Colors.grey, + color: const Color.fromRGBO(51, 51, 51, 1), ), Expanded( child: TextField( @@ -97,7 +97,7 @@ class SearchPage extends StatelessWidget { Text( "仅支持搜索", style: TextStyle( - color: const Color.fromRGBO(121, 121, 121, 1) + color: const Color.fromRGBO(189, 189, 189, 1) ), ), Text( diff --git a/lib/pages/home/content_card.dart b/lib/pages/home/content_card.dart index 423beb5..661cad4 100644 --- a/lib/pages/home/content_card.dart +++ b/lib/pages/home/content_card.dart @@ -55,6 +55,7 @@ class _CardHeader extends StatelessWidget { ), ), errorWidget: (context, url, error) => Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 60, height: 60, @@ -106,6 +107,7 @@ class _CardHeader extends StatelessWidget { mainAxisSize: MainAxisSize.min, // 确保Row只占用必要的宽度 children: [ Image.asset( + gaplessPlayback: true, Assets.imagesVerifiedIcon, width: 14, height: 12, @@ -205,6 +207,7 @@ class _CardHeader extends StatelessWidget { } }, child: !item.liveStreaming ? Image.asset( + gaplessPlayback: true, _getButtonImage(isLive, isOnline), width: item.liveStreaming ? 60 : 50, height: 30, @@ -377,6 +380,7 @@ class _NetworkImageWidget extends StatelessWidget { ), ), errorWidget: (context, url, error) => Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 60, height: 60, diff --git a/lib/pages/home/home_page.dart b/lib/pages/home/home_page.dart index f321f93..9f6c179 100644 --- a/lib/pages/home/home_page.dart +++ b/lib/pages/home/home_page.dart @@ -31,8 +31,13 @@ class _HomePageState extends State builder: (controller) { return Stack( children: [ + + Positioned.fill( + child: Container(color: Colors.white,), + ), // 背景图 - 覆盖整个屏幕包括状态栏和导航栏 Image.asset( + gaplessPlayback: true, Assets.imagesBgInformation, fit: BoxFit.cover, width: double.infinity, @@ -62,9 +67,9 @@ class _HomePageState extends State index: controller.selectedTabIndex.value, children: const [ // 同城列表 + RecommendTab(), AllTimeline(), // 推荐列表 - RecommendTab(), NearbyTab() ], ); @@ -86,9 +91,9 @@ class _HomePageState extends State mainAxisAlignment: MainAxisAlignment.center, mainAxisSize: MainAxisSize.min, children: [ - _buildTabButton(title: '广场', index: 0, controller: controller), + _buildTabButton(title: '推荐', index: 0, controller: controller), const SizedBox(width: 28), - _buildTabButton(title: '推荐', index: 1, controller: controller), + _buildTabButton(title: '广场', index: 1, controller: controller), const SizedBox(width: 28), _buildTabButton(title: '同城', index: 2, controller: controller), ], @@ -131,7 +136,8 @@ class _HomePageState extends State ), const SizedBox(height: 6), selected - ? Image.asset(Assets.imagesTabChangeIcon, width: 32, height: 8) + ? Image.asset(Assets.imagesTabChangeIcon, width: 32, height: 8, + gaplessPlayback: true,) : const SizedBox(height: 8), ], ), diff --git a/lib/pages/home/timeline_item.dart b/lib/pages/home/timeline_item.dart index 7306b08..9c52e3b 100644 --- a/lib/pages/home/timeline_item.dart +++ b/lib/pages/home/timeline_item.dart @@ -54,6 +54,7 @@ class _TimelineItemState extends State { Padding( padding: EdgeInsets.symmetric(horizontal: 0), child: Image.asset( + gaplessPlayback: true, emoji.path, width: 24.w, height: 24.w, @@ -156,6 +157,24 @@ class _TimelineItemState extends State { width: 40.w, height: 40.w, fit: BoxFit.cover, + + + imageBuilder: (context, imageProvider) => Container( + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(40), + image: DecorationImage( + image: imageProvider, + fit: BoxFit.cover, + ), + ), + ), + errorWidget: (context, url, error) => Image.asset( + gaplessPlayback: true, + Assets.imagesUserAvatar, + width: 105.w, + height: 105.w, + fit: BoxFit.cover, + ), ), ).onTap((){ Get.to(() => UserInformationPage(miId: widget.item.miId ?? "")); @@ -235,6 +254,7 @@ class _TimelineItemState extends State { ), ), errorWidget: (context, url, error) => Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 341.w, height: 341.w, @@ -263,6 +283,7 @@ class _TimelineItemState extends State { ), ), errorWidget: (context, url, error) => Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 165.w, height: 165.w, @@ -295,6 +316,7 @@ class _TimelineItemState extends State { ), ), errorWidget: (context, url, error) => Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 105.w, height: 105.w, @@ -313,6 +335,7 @@ class _TimelineItemState extends State { Row( children: [ Image.asset( + gaplessPlayback: true, (widget.item.isLiked ?? false) ? Assets.imagesLikeActive : Assets.imagesLikeIcon, width: 14.w, height: 12.w, @@ -333,6 +356,7 @@ class _TimelineItemState extends State { Row( children: [ Image.asset( + gaplessPlayback: true, Assets.imagesCommentIcon, width: 15.w, height: 15.w, diff --git a/lib/pages/main/main_page.dart b/lib/pages/main/main_page.dart index 9dcbd65..4457854 100644 --- a/lib/pages/main/main_page.dart +++ b/lib/pages/main/main_page.dart @@ -96,9 +96,10 @@ class _MainPageState extends State { children: [ _buildBottomNavigationBar(), Positioned( + left: MediaQuery.of(context).size.width / 2 - 30, top: -20, - left: 150, child: Image.asset( + gaplessPlayback: true, Assets.imagesPublish, width: 60, height: 60, @@ -135,8 +136,10 @@ class _MainPageState extends State { tabItem('找对象', Assets.imagesDiscoverPre, Assets.imagesDiscoverNol, 1, 0), TDBottomTabBarTabConfig( tabText: "", - selectedIcon: Image.asset(Assets.imagesHomePre, width: 30, height: 30, fit: BoxFit.cover, color: Colors.transparent,), - unselectedIcon: Image.asset(Assets.imagesHomeNol, width: 30, height: 30, fit: BoxFit.cover, color: Colors.transparent,), + selectedIcon: Image.asset( + gaplessPlayback: true,Assets.imagesHomePre, width: 30, height: 30, fit: BoxFit.cover, color: Colors.transparent,), + unselectedIcon: Image.asset( + gaplessPlayback: true,Assets.imagesHomeNol, width: 30, height: 30, fit: BoxFit.cover, color: Colors.transparent,), onTap: (){ Get.to(() => SendTimeline()); } @@ -152,8 +155,10 @@ class _MainPageState extends State { TDBottomTabBarTabConfig tabItem(String title, String selectedIcon, String unselectedIcon, int index, int unreadCount) { return TDBottomTabBarTabConfig( tabText: title, - selectedIcon: Image.asset(selectedIcon, width: 30, height: 30, fit: BoxFit.cover), - unselectedIcon: Image.asset(unselectedIcon, width: 30, height: 30, fit: BoxFit.cover), + selectedIcon: Image.asset( + gaplessPlayback: true,selectedIcon, width: 30, height: 30, fit: BoxFit.cover), + unselectedIcon: Image.asset( + gaplessPlayback: true,unselectedIcon, width: 30, height: 30, fit: BoxFit.cover), selectTabTextStyle: TextStyle(color: Color(0xFFED4AC3)), unselectTabTextStyle: TextStyle(color: Color(0xFF999999)), badgeConfig: BadgeConfig( diff --git a/lib/pages/message/conversation_tab.dart b/lib/pages/message/conversation_tab.dart index 4f4c156..e4cd88f 100644 --- a/lib/pages/message/conversation_tab.dart +++ b/lib/pages/message/conversation_tab.dart @@ -29,43 +29,51 @@ class _ConversationTabState extends State super.build(context); return Column( children: [ - Container( - padding: EdgeInsets.symmetric( - horizontal: 22.w - ), - child: Row( - children: [ - Column( + Obx((){ + if(!controller.isSearch.value){ + return Container( + padding: EdgeInsets.symmetric( + horizontal: 22.w + ), + child: Row( children: [ - Container( - width: 90.w, - height: 50.w, - margin: EdgeInsets.only(bottom: 5.w), - decoration: BoxDecoration( - color: const Color.fromRGBO(226, 222, 255, 1), - borderRadius: BorderRadius.all(Radius.circular(50.w)) - ), - child: Center( - child: Image.asset( - Assets.imagesConnectHistoryIcon, - width: 40.w, - height: 40.w, + Column( + children: [ + Container( + width: 90.w, + height: 50.w, + margin: EdgeInsets.only(bottom: 5.w), + decoration: BoxDecoration( + color: const Color.fromRGBO(226, 222, 255, 1), + borderRadius: BorderRadius.all(Radius.circular(50.w)) + ), + child: Center( + child: Image.asset( + gaplessPlayback: true, + Assets.imagesConnectHistoryIcon, + width: 40.w, + height: 40.w, + ), + ), ), - ), - ), - Text( - "连线记录", - style: TextStyle( - fontSize: 11.w - ), - ) + Text( + "连线记录", + style: TextStyle( + fontSize: 11.w + ), + ) + ], + ).onTap((){ + Get.to(() => ConnectHistoryPage()); + }) ], - ).onTap((){ - Get.to(() => ConnectHistoryPage()); - }) - ], - ), - ), + ), + ); + } else { + return SizedBox(); + } + + }), // 聊天列表 Expanded( child: Obx(() { @@ -219,12 +227,14 @@ class _BuildConversationItemState extends State { height: 56, fit: BoxFit.cover, placeholder: (context, url) => Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 56, height: 56, fit: BoxFit.cover, ), errorWidget: (context, url, error) => Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 56, height: 56, @@ -232,6 +242,7 @@ class _BuildConversationItemState extends State { ), ) : Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 56, height: 56, @@ -429,6 +440,7 @@ class _BuildConversationItemState extends State { child: Padding( padding: EdgeInsets.symmetric(horizontal: 2.w), child: Image.asset( + gaplessPlayback: true, emoji.path, width: 16.w, height: 16.w, diff --git a/lib/pages/message/message_page.dart b/lib/pages/message/message_page.dart index 65df047..e84e713 100644 --- a/lib/pages/message/message_page.dart +++ b/lib/pages/message/message_page.dart @@ -41,6 +41,7 @@ class _MessagePageState extends State with AutomaticKeepAliveClient super.build(context); return Container( decoration: BoxDecoration( + color: Colors.white, image: DecorationImage( image: AssetImage(Assets.imagesBgInformation), fit: BoxFit.cover, @@ -71,24 +72,24 @@ class _MessagePageState extends State with AutomaticKeepAliveClient ), actions: [ Container( - width: 243, + width: !controller.showSearch.value ? 200 : 270, child: Row( mainAxisAlignment: MainAxisAlignment.end, children: [ if(controller.showSearch.value) Expanded( child: Container( - height: 30.w, + height: 27.w, padding: EdgeInsets.symmetric(horizontal: 10), decoration: BoxDecoration( - borderRadius: BorderRadius.all(Radius.circular(30.w)), - color: const Color.fromRGBO(200, 200, 200, 1.0) + borderRadius: BorderRadius.all(Radius.circular(27.w)), + color: Colors.white ), child: Row( children: [ Icon( Icons.search, size: 20, - color: Colors.grey, + color: const Color.fromRGBO(144, 144, 144, 1) ), Expanded( child: TextField( @@ -129,12 +130,6 @@ class _MessagePageState extends State with AutomaticKeepAliveClient SizedBox(width: 10,), Row( children: [ - Container( - height: 15, - width: 1, - color: const Color.fromRGBO(51, 51, 51, 1), - ), - SizedBox(width: 10,), Text( "搜索", style: TextStyle( @@ -150,13 +145,44 @@ class _MessagePageState extends State with AutomaticKeepAliveClient ), ), SizedBox(width: 10,), - Icon( - Icons.search, - size: 30, + if(!controller.showSearch.value) Container( + width: 60.w, + height: 27.w, + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(27.w)), + color: Colors.white + ), + child: Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Icon( + Icons.search, + size: 15.w, + ), + Text( + "搜索", + style: TextStyle( + fontSize: 12.w + ), + ) + ], + ), ).onTap((){ controller.showSearch.value = !controller.showSearch.value; setState(() { + }); + }), + if(controller.showSearch.value) Text( + "收起", + style: TextStyle( + fontSize: 14.w + ), + ).onTap((){ + controller.isSearch.value = false; + controller.showSearch.value = !controller.showSearch.value; + setState(() { + }); }) ], @@ -164,15 +190,31 @@ class _MessagePageState extends State with AutomaticKeepAliveClient ), SizedBox(width: 10,), // 过滤器按钮 - GestureDetector( + if(!controller.showSearch.value) GestureDetector( key: _filterButtonKey, onTap: () => _showFilterMenu(context), child: Container( - width: 20, - height: 20, + width: 60.w, + height: 27.w, margin: const EdgeInsets.only(right: 16), alignment: Alignment.center, - child: Image.asset(Assets.imagesFilterIcon, width: 20,), + decoration: BoxDecoration( + borderRadius: BorderRadius.all(Radius.circular(27.w)), + color: Colors.white + ), + child: Row( + mainAxisAlignment: MainAxisAlignment.center, + children: [ + Image.asset(Assets.imagesFilterIcon, width: 12.w, + gaplessPlayback: true,), + Text( + "筛选", + style: TextStyle( + fontSize: 12.w + ), + ) + ], + ), ), ), ], @@ -210,6 +252,7 @@ class _MessagePageState extends State with AutomaticKeepAliveClient const SizedBox(height: 6), isSelected ? Image.asset( + gaplessPlayback: true, Assets.imagesTabChangeIcon, width: 20, ) @@ -327,6 +370,7 @@ class _MessagePageState extends State with AutomaticKeepAliveClient child: Row( children: [ Image.asset( + gaplessPlayback: true, icon, width: 20, height: 20, diff --git a/lib/pages/mine/mine_page.dart b/lib/pages/mine/mine_page.dart index d6d0832..4a79128 100644 --- a/lib/pages/mine/mine_page.dart +++ b/lib/pages/mine/mine_page.dart @@ -150,6 +150,7 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ ), ), ) : Image.asset( + gaplessPlayback: true, Assets.imagesUserAvatar, width: 60.w, height: 60.w, @@ -191,6 +192,7 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ ), child: Center( child: Image.asset( + gaplessPlayback: true, Assets.imagesVipFont, width: 20.w, height: 8.w, @@ -226,6 +228,7 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ child: Row( children: [ Image.asset( + gaplessPlayback: true, Assets.imagesEdit, width: 10.w, height: 10.w, @@ -296,7 +299,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ style: cellStyle, cells: [ TDCell(arrow: true, - leftIconWidget: Image.asset(Assets.imagesRose, height: 22.w, width: 22.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,Assets.imagesRose, height: 22.w, width: 22.w), titleWidget: Text( "我的玫瑰", style: TextStyle( @@ -307,7 +311,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ } ), TDCell(arrow: true, - leftIconWidget: Image.asset(Assets.imagesWallet, height: 22.w, width: 22.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,Assets.imagesWallet, height: 22.w, width: 22.w), titleWidget: Text( "我的钱包", style: TextStyle( @@ -318,7 +323,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ } ), TDCell(arrow: true, - leftIconWidget: Image.asset(Assets.imagesCert, height: 22.w, width: 22.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,Assets.imagesCert, height: 22.w, width: 22.w), titleWidget: Text( "认证中心", style: TextStyle( @@ -342,7 +348,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ } ), TDCell(arrow: true, - leftIconWidget: Image.asset(Assets.imagesMatchmaker, height: 22.w, width: 22.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,Assets.imagesMatchmaker, height: 22.w, width: 22.w), titleWidget: Text( "红娘等级", style: TextStyle( @@ -353,7 +360,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ } ), if(controller.matchmakerFlag.value)TDCell(arrow: true, - leftIconWidget: Image.asset('assets/images/matcher_task.png', height: 20.w, width: 18.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,'assets/images/matcher_task.png', height: 20.w, width: 18.w), titleWidget: Text( " 红娘任务", style: TextStyle( @@ -373,7 +381,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ style: cellStyle, cells: [ TDCell(arrow: true, - leftIconWidget: Image.asset(Assets.imagesSetting, height: 22.w, width: 22.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,Assets.imagesSetting, height: 22.w, width: 22.w), titleWidget: Text( "设置", style: TextStyle( @@ -384,7 +393,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ } ), TDCell(arrow: true, - leftIconWidget: Image.asset(Assets.imagesCustomer, height: 22.w, width: 22.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,Assets.imagesCustomer, height: 22.w, width: 22.w), titleWidget: Text( "联系客服", style: TextStyle( @@ -395,7 +405,8 @@ class MinePageState extends State with AutomaticKeepAliveClientMixin{ } ), TDCell(arrow: true, - leftIconWidget: Image.asset(Assets.imagesMail, height: 22.w, width: 22.w), + leftIconWidget: Image.asset( + gaplessPlayback: true,Assets.imagesMail, height: 22.w, width: 22.w), titleWidget: Text( "意见反馈", style: TextStyle(