From e4fe4607a4f490262e7d5b3a46780026e03be67c Mon Sep 17 00:00:00 2001 From: Christophe Deschamps Date: Wed, 29 Dec 2021 18:29:30 +0100 Subject: [PATCH] Make chatroom deletion waiting modal to prevent crash --- Classes/ChatsListTableView.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Classes/ChatsListTableView.m b/Classes/ChatsListTableView.m index ba82444af..6f8c3fd36 100644 --- a/Classes/ChatsListTableView.m +++ b/Classes/ChatsListTableView.m @@ -24,6 +24,8 @@ #import "linphone/linphonecore.h" #import "PhoneMainView.h" #import "Utils.h" +#import "SVProgressHUD.h" + @implementation ChatsListTableView @@ -202,11 +204,13 @@ void deletion_chat_room_state_changed(LinphoneChatRoom *cr, LinphoneChatRoomStat // will force a call to [self loadData] [NSNotificationCenter.defaultCenter postNotificationName:kLinphoneMessageReceived object:view]; view.waitView.hidden = TRUE; + [SVProgressHUD dismiss]; } } - (void) deleteChatRooms { _waitView.hidden = FALSE; + [SVProgressHUD show]; bctbx_list_t *chatRooms = bctbx_list_copy(_chatRooms); while (chatRooms) { LinphoneChatRoom *chatRoom = (LinphoneChatRoom *)chatRooms->data;