Set explicit height for all media types. Audio is the only special case. (#1237)

This might FIX #1111, but I think there are actually a handful of things
breaking our layout.

// FREEBIE
pull/1/head
Michael Kirk 9 years ago committed by GitHub
parent 87d2fe1131
commit b3bb4c745e

@ -39,7 +39,6 @@
self = [super initWithFileURL:[attachment mediaURL] isReadyToPlay:YES]; self = [super initWithFileURL:[attachment mediaURL] isReadyToPlay:YES];
if (self) { if (self) {
;
_image = attachment.image; _image = attachment.image;
_cachedImageView = nil; _cachedImageView = nil;
_attachmentId = attachment.uniqueId; _attachmentId = attachment.uniqueId;
@ -200,15 +199,11 @@
} }
- (CGSize)mediaViewDisplaySize { - (CGSize)mediaViewDisplaySize {
CGSize mediaDisplaySize;
if ([self isVideo]) {
mediaDisplaySize = [super mediaViewDisplaySize];
} else if ([self isAudio]) {
CGSize size = [super mediaViewDisplaySize]; CGSize size = [super mediaViewDisplaySize];
if ([self isAudio]) {
size.height = AUDIO_BAR_HEIGHT; size.height = AUDIO_BAR_HEIGHT;
mediaDisplaySize = size;
} }
return mediaDisplaySize; return size;
} }
- (UIView *)mediaPlaceholderView { - (UIView *)mediaPlaceholderView {

Loading…
Cancel
Save