From 54395a72521f2fd3e5a7105a2c3baeb75c749a6f Mon Sep 17 00:00:00 2001 From: "B. Petersen" Date: Thu, 30 Apr 2020 16:56:43 +0200 Subject: [PATCH] do not send DC_EVENT_MSGS_CHANGED or DC_EVENT_INCOMING_MSG for hidden messages these events take the message-id as parameter and might be used to update an existing list (although to recommended) if the event is issued for hidden messages, this might led to "empty" messages flashing up - the ui tries to get the message from the event, after a moment, on the next update, the message disappears again as hidden messages are of course not returned eg. by dc_get_chat_msgs(). the effect was probably always visible for secure-join-messages on ios, however, become much more visible recently when read-receipts are added as hidden messages as well (to make them auto-deletable). --- src/dc_receive_imf.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dc_receive_imf.rs b/src/dc_receive_imf.rs index e3d589360..4730d540a 100644 --- a/src/dc_receive_imf.rs +++ b/src/dc_receive_imf.rs @@ -674,7 +674,7 @@ fn add_parts( ); // check event to send - if chat_id.is_trash() { + if chat_id.is_trash() || *hidden { *create_event_to_send = None; } else if incoming && state == MessageState::InFresh { if from_id_blocked {