説明なし

FKPhoneNumberCell.m 1.1KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. //
  2. // FKPhoneNumberCell.m
  3. // FirstLink
  4. //
  5. // Created by jack on 16/5/26.
  6. // Copyright © 2016年 FirstLink. All rights reserved.
  7. //
  8. #import "FKPhoneNumberCell.h"
  9. @implementation FKPhoneNumberCell
  10. - (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier{
  11. if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
  12. [self addAllSubviews];
  13. self.contentView.backgroundColor = [UIColor whiteColor];
  14. self.selectionStyle = UITableViewCellSelectionStyleNone;
  15. }
  16. return self;
  17. }
  18. - (void)addAllSubviews{
  19. [self.contentView addSubview:self.titleLabel];
  20. [self.titleLabel mas_makeConstraints:^(MASConstraintMaker *make) {
  21. make.left.equalTo(self.contentView).offset(15);
  22. make.centerY.equalTo(self.contentView);
  23. }];
  24. }
  25. - (UILabel *)titleLabel{
  26. if (_titleLabel == nil) {
  27. _titleLabel = [[UILabel alloc]init];
  28. _titleLabel.font = [UIFont systemFontOfSize:15];
  29. _titleLabel.textColor = UIColorFromRGB(0x333333);
  30. }
  31. return _titleLabel;
  32. }
  33. @end