Add support for reporting rooms on the room details screen too

This commit is contained in:
Stefan Ceriu
2024-06-12 17:43:35 +03:00
parent 87577f5692
commit b691d02a20
15 changed files with 51 additions and 6 deletions
+8 -3
View File
@@ -5372,10 +5372,10 @@ static CGSize kThreadListBarButtonItemImageSize;
}
}
- (void)handleReportRoomButtonPress
- (void)handleReportRoom
{
// Prompt user to enter a description of the problem content.
UIAlertController *reportReasonAlert = [UIAlertController alertControllerWithTitle:[VectorL10n roomEventActionReportPromptReason]
UIAlertController *reportReasonAlert = [UIAlertController alertControllerWithTitle:[VectorL10n roomActionReportPromptReason]
message:nil
preferredStyle:UIAlertControllerStyleAlert];
@@ -5663,7 +5663,7 @@ static CGSize kThreadListBarButtonItemImageSize;
}
else if (tappedView == previewHeader.reportButton)
{
[self handleReportRoomButtonPress];
[self handleReportRoom];
}
}
@@ -8032,6 +8032,11 @@ static CGSize kThreadListBarButtonItemImageSize;
[self reloadRoomWihtEventId:event.eventId threadId:event.threadId forceUpdateRoomMarker:NO];
}
- (void)roomInfoCoordinatorBridgePresenterDidRequestReportRoom:(RoomInfoCoordinatorBridgePresenter *)coordinatorBridgePresenter
{
[self handleReportRoom];
}
-(void)reloadRoomWihtEventId:(NSString *)eventId
threadId:(NSString *)threadId
forceUpdateRoomMarker:(BOOL)forceUpdateRoomMarker