Check whether URL previews should be shown in a single location.

Reset all cell data when this setting is changed to force a refresh.
Rename `hasClosedPreview(from:)` to `shouldShowPreview(for:)` for clarity and potentially adding more rules at a later date.
This commit is contained in:
Doug
2021-09-29 11:39:11 +01:00
parent 57018f90ee
commit bf84540b39
4 changed files with 9 additions and 11 deletions
@@ -372,7 +372,7 @@ const CGFloat kTypingCellHeight = 24;
URLPreviewView *urlPreviewView;
// Show a URL preview if the component has a link that should be previewed.
if (RiotSettings.shared.roomScreenShowsURLPreviews && component.showURLPreview)
if (component.showURLPreview)
{
urlPreviewView = [URLPreviewView instantiate];
urlPreviewView.preview = component.urlPreviewData;