diff --git a/Riot/Modules/Room/RoomViewController.m b/Riot/Modules/Room/RoomViewController.m index a5c28e3c0..9053a7439 100644 --- a/Riot/Modules/Room/RoomViewController.m +++ b/Riot/Modules/Room/RoomViewController.m @@ -2179,7 +2179,8 @@ static CGSize kThreadListBarButtonItemImageSize; - (void)handleLongPressFromCell:(id)cell withTappedEvent:(MXEvent*)event { - if (event && !self.customizedRoomDataSource.selectedEventId) + // bwi: disable context menu for state events + if (event && !self.customizedRoomDataSource.selectedEventId && !event.isState) { [self showContextualMenuForEvent:event fromSingleTapGesture:NO cell:cell animated:YES]; } @@ -3628,7 +3629,7 @@ static CGSize kThreadListBarButtonItemImageSize; } else { - // Show contextual menu on single tap if bubble is not collapsed + // bwi: Show contextual menu on single tap if bubble is not collapsed and if its not a state event if (bubbleData.collapsed) { [self selectEventWithId:tappedEvent.eventId]; @@ -3638,7 +3639,9 @@ static CGSize kThreadListBarButtonItemImageSize; if (tappedEvent.location) { [_delegate roomViewController:self didRequestLocationPresentationForEvent:tappedEvent bubbleData:bubbleData]; } else { - [self showContextualMenuForEvent:tappedEvent fromSingleTapGesture:YES cell:cell animated:YES]; + if (!tappedEvent.isState) { + [self showContextualMenuForEvent:tappedEvent fromSingleTapGesture:YES cell:cell animated:YES]; + } } } }