Skip to content

Commit

Permalink
Remove ”copy” action for location events (#1355)
Browse files Browse the repository at this point in the history
* Hide ”copy” action for location events

* Cleanup
  • Loading branch information
alfogrillo authored Jul 18, 2023
1 parent ad1422a commit cf39710
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -411,7 +411,7 @@ class RoomScreenViewModel: RoomScreenViewModelType, RoomScreenViewModelProtocol
actions.append(.edit)
}

if item.isMessage {
if item.isMessage, !item.isLocation {
actions.append(.copy)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ extension EventBasedTimelineItemProtocol {
self is EventBasedMessageTimelineItemProtocol
}

var isLocation: Bool {
self is LocationRoomTimelineItem
}

var isRedacted: Bool {
self is RedactedRoomTimelineItem
}
Expand Down

0 comments on commit cf39710

Please sign in to comment.