Temporarily alter animations in conversation view.

pull/1/head
Matthew Chen 8 years ago
parent af6a7c103c
commit bf0f33e4b0

@ -2943,7 +2943,7 @@ typedef NS_ENUM(NSInteger, MessagesRangeSizeMode) {
[self updateLastVisibleTimestamp]; [self updateLastVisibleTimestamp];
if (scrollToBottom) { if (scrollToBottom) {
[self scrollToBottomAnimated:shouldAnimateScrollToBottom]; [self scrollToBottomAnimated:shouldAnimateScrollToBottom && shouldAnimateUpdates];
} }
}; };
@ -2953,7 +2953,7 @@ typedef NS_ENUM(NSInteger, MessagesRangeSizeMode) {
// We want these animations to be as short as possible, but `performBatchUpdates` // We want these animations to be as short as possible, but `performBatchUpdates`
// will SIGABORT in some cases if the animation duration is zero. // will SIGABORT in some cases if the animation duration is zero.
[CATransaction begin]; [CATransaction begin];
[CATransaction setAnimationDuration:0.05f]; [CATransaction setAnimationDuration:0.001f];
[self.collectionView performBatchUpdates:batchUpdates completion:batchUpdatesCompletion]; [self.collectionView performBatchUpdates:batchUpdates completion:batchUpdatesCompletion];
[CATransaction commit]; [CATransaction commit];
} }

Loading…
Cancel
Save