RoomVC: Prevent tableView scroll when displaying contextual menu (Fix #2687).

This commit is contained in:
SBiOSoftWhare
2019-10-28 18:55:55 +01:00
parent a3fb9718d8
commit f520f83d3f
+6 -3
View File
@@ -522,8 +522,7 @@
// Observe kAppDelegateDidTapStatusBarNotification.
kAppDelegateDidTapStatusBarNotificationObserver = [[NSNotificationCenter defaultCenter] addObserverForName:kAppDelegateDidTapStatusBarNotification object:nil queue:[NSOperationQueue mainQueue] usingBlock:^(NSNotification *notif) {
[self.bubblesTableView setContentOffset:CGPointMake(-self.bubblesTableView.mxk_adjustedContentInset.left, -self.bubblesTableView.mxk_adjustedContentInset.top) animated:YES];
[self setBubbleTableViewContentOffset:CGPointMake(-self.bubblesTableView.mxk_adjustedContentInset.left, -self.bubblesTableView.mxk_adjustedContentInset.top) animated:YES];
}];
}
@@ -859,7 +858,7 @@
// Disable VoiceOver while scrolling
self.bubblesTableView.accessibilityElementsHidden = YES;
[self.bubblesTableView setContentOffset:offset animated:NO];
[self setBubbleTableViewContentOffset:offset animated:NO];
NSEnumerator<UITableViewCell*> *cells;
if (direction == UIAccessibilityScrollDirectionUp)
@@ -5437,7 +5436,9 @@
completion:^{
}];
preventBubblesTableViewScroll = YES;
[self selectEventWithId:selectedEventId];
preventBubblesTableViewScroll = NO;
}
- (void)hideContextualMenuAnimated:(BOOL)animated
@@ -5459,7 +5460,9 @@
if (cancelEventSelection)
{
preventBubblesTableViewScroll = YES;
[self cancelEventSelection];
preventBubblesTableViewScroll = NO;
}
[self.roomContextualMenuPresenter hideContextualMenuWithAnimated:animated completion:^{