diff --git a/Vector/Assets/en.lproj/Vector.strings b/Vector/Assets/en.lproj/Vector.strings index 864285b5e..3047bcba2 100644 --- a/Vector/Assets/en.lproj/Vector.strings +++ b/Vector/Assets/en.lproj/Vector.strings @@ -170,6 +170,7 @@ "room_event_action_more" = "More"; "room_event_action_share" = "Share"; "room_event_action_permalink" = "Permalink"; +"room_event_action_view_source" = "View Source"; "room_event_action_report" = "Report content"; "room_event_action_report_prompt_reason" = "Reason for reporting this content"; "room_event_action_report_prompt_ignore_user" = "Do you want to hide all messages from this user?"; diff --git a/Vector/ViewController/RoomViewController.m b/Vector/ViewController/RoomViewController.m index 7c8364536..11f0c2443 100644 --- a/Vector/ViewController/RoomViewController.m +++ b/Vector/ViewController/RoomViewController.m @@ -1748,6 +1748,18 @@ }]; } + if (level == 1) + { + [currentAlert addActionWithTitle:NSLocalizedStringFromTable(@"room_event_action_view_source", @"Vector", nil) style:MXKAlertActionStyleDefault handler:^(MXKAlert *alert) { + + __strong __typeof(weakSelf)strongSelf = weakSelf; + [strongSelf cancelEventSelection]; + + // Display event details + [strongSelf showEventDetails:selectedEvent]; + }]; + } + if (level == 1) { [currentAlert addActionWithTitle:NSLocalizedStringFromTable(@"room_event_action_report", @"Vector", nil) style:MXKAlertActionStyleDefault handler:^(MXKAlert *alert) {