From 3bf383895b6fe43ba6db50f4ee9c0a676ce75448 Mon Sep 17 00:00:00 2001 From: Kelrap Date: Wed, 29 May 2024 09:50:52 -0400 Subject: [PATCH] Remove option doesn't show for non-text/multiple messages --- lib/pages/chat/chat_view.dart | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/lib/pages/chat/chat_view.dart b/lib/pages/chat/chat_view.dart index 21789f527f..77be689810 100644 --- a/lib/pages/chat/chat_view.dart +++ b/lib/pages/chat/chat_view.dart @@ -42,11 +42,15 @@ class ChatView extends StatelessWidget { tooltip: L10n.of(context)!.edit, onPressed: controller.editSelectedEventAction, ), - IconButton( - icon: const Icon(Icons.copy_outlined), - tooltip: L10n.of(context)!.copy, - onPressed: controller.copyEventsAction, - ), + // #Pangea + if (controller.selectedEvents.length == 1 && + controller.selectedEvents.single.messageType == MessageTypes.Text) + // Pangea# + IconButton( + icon: const Icon(Icons.copy_outlined), + tooltip: L10n.of(context)!.copy, + onPressed: controller.copyEventsAction, + ), if (controller.canSaveSelectedEvent) // Use builder context to correctly position the share dialog on iPad Builder( @@ -116,8 +120,10 @@ class ChatView extends StatelessWidget { // #Pangea } else { return [ - ChatSettingsPopupMenu(controller.room, - (!controller.room.isDirectChat && !controller.room.isArchived)), + ChatSettingsPopupMenu( + controller.room, + (!controller.room.isDirectChat && !controller.room.isArchived), + ), ]; }