From b67179b45df07eb127ad2d067eab403a36484566 Mon Sep 17 00:00:00 2001 From: Matthew Chen Date: Thu, 16 Nov 2017 17:53:05 -0500 Subject: [PATCH] Skip animations in conversation view. --- .../ConversationView/ConversationViewController.m | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Signal/src/ViewControllers/ConversationView/ConversationViewController.m b/Signal/src/ViewControllers/ConversationView/ConversationViewController.m index bc4acffa5..89123a5df 100644 --- a/Signal/src/ViewControllers/ConversationView/ConversationViewController.m +++ b/Signal/src/ViewControllers/ConversationView/ConversationViewController.m @@ -2965,10 +2965,9 @@ typedef NS_ENUM(NSInteger, MessagesRangeSizeMode) { } else { // We want these animations to be as short as possible, but `performBatchUpdates` // will SIGABORT in some cases if the animation duration is zero. - [CATransaction begin]; - [CATransaction setAnimationDuration:0.001f]; - [self.collectionView performBatchUpdates:batchUpdates completion:batchUpdatesCompletion]; - [CATransaction commit]; + [UIView performWithoutAnimation:^{ + [self.collectionView performBatchUpdates:batchUpdates completion:batchUpdatesCompletion]; + }]; } }