diff --git a/lib/pages/forward/recent_chat_list.dart b/lib/pages/forward/recent_chat_list.dart index bbf7207445..796ea4db69 100644 --- a/lib/pages/forward/recent_chat_list.dart +++ b/lib/pages/forward/recent_chat_list.dart @@ -38,7 +38,6 @@ class RecentChatList extends StatelessWidget { itemCount: rooms.length, itemBuilder: (BuildContext context, int index) { final room = rooms[index]; - final selected = selectedChat == room.id; return Material( borderRadius: RecentChatListStyle.borderRadiusItem, child: InkWell( @@ -48,16 +47,10 @@ class RecentChatList extends StatelessWidget { padding: RecentChatListStyle.paddingVerticalBetweenItem, child: Row( children: [ - AnimatedCrossFade( - duration: durationToggleItem, - firstChild: Checkbox( - value: selected, - onChanged: (value) => onSelectedChat(room.id), - ), - secondChild: const SizedBox.shrink(), - crossFadeState: selected - ? CrossFadeState.showFirst - : CrossFadeState.showSecond, + Radio( + groupValue: room.id, + value: selectedChat, + onChanged: (value) => onSelectedChat(room.id), ), Avatar( mxContent: room.avatar, diff --git a/lib/pages/share/share_view.dart b/lib/pages/share/share_view.dart index 3ebceb3ef8..0e43bd1edd 100644 --- a/lib/pages/share/share_view.dart +++ b/lib/pages/share/share_view.dart @@ -60,7 +60,7 @@ class ShareView extends StatelessWidget { floatingActionButton: ValueListenableBuilder( valueListenable: controller.selectedChatNotifier, builder: ((context, selectedEvents, child) { - if (selectedEvents.length != 1) { + if (selectedEvents.isEmpty) { return const SizedBox(); }