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
This commit is contained in:
Michael Kirk 2016-06-28 06:50:12 -07:00 committed by GitHub
parent 87d2fe1131
commit b3bb4c745e
1 changed files with 4 additions and 9 deletions

View File

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