Skip to content

Commit ab5ecad

Browse files
committed
Merge pull request forkingdog#377 from miniLV:master
1 parent c624e4d commit ab5ecad

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

Classes/UITableView+FDTemplateLayoutCell.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,10 @@ - (__kindof UITableViewCell *)fd_templateCellForReuseIdentifier:(NSString *)iden
158158
templateCell = [self dequeueReusableCellWithIdentifier:identifier];
159159
NSAssert(templateCell != nil, @"Cell must be registered to table view for identifier - %@", identifier);
160160
templateCell.fd_isTemplateLayoutCell = YES;
161-
templateCell.contentView.translatesAutoresizingMaskIntoConstraints = NO;
161+
NSString *version = [UIDevice currentDevice].systemVersion;
162+
if (version.doubleValue < 11.0){
163+
templateCell.contentView.translatesAutoresizingMaskIntoConstraints = NO;
164+
}
162165
templateCellsByIdentifiers[identifier] = templateCell;
163166
[self fd_debugLog:[NSString stringWithFormat:@"layout cell created - %@", identifier]];
164167
}

0 commit comments

Comments
 (0)