Merge branch 'master' into development

This commit is contained in:
Wenchao Ding 2016-07-28 22:00:48 +08:00
commit 91c93e3eb0
1 changed files with 3 additions and 2 deletions

View File

@ -165,7 +165,8 @@
self.contentView.hidden = (currentLine>lineCount);
}
}
} else {
} else if (self.contentView.hidden) {
self.needsAdjustingViewFrame = YES;
self.contentView.hidden = NO;
}
@ -436,7 +437,7 @@
- (void)setSubtitle:(NSString *)subtitle
{
if (![_subtitle isEqualToString:subtitle]) {
_needsAdjustingViewFrame = !(_subtitle.length && subtitle.length);
_needsAdjustingViewFrame = (subtitle.length && !_subtitle.length) || (_subtitle.length && !subtitle.length);
_subtitle = subtitle;
if (_needsAdjustingViewFrame) {
[self setNeedsLayout];