YRHomeFooter.m 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. //
  2. // YRHomeFooter.m
  3. // UU_Ent
  4. //
  5. // Created by liujl on 2019/9/20.
  6. // Copyright © 2019 UAS. All rights reserved.
  7. //
  8. #import "YRHomeFooter.h"
  9. @implementation YRHomeFooter
  10. - (instancetype)initWithFrame:(CGRect)frame
  11. {
  12. self = [super initWithFrame:frame];
  13. if (self) {
  14. [self createUI];
  15. }
  16. return self;
  17. }
  18. -(void)createUI{
  19. self.backgroundColor = HexColor(@"#F6F6F6");
  20. UIImageView *addView = [[UIImageView alloc]initWithImage:[UIImage imageNamed:@"UU_首页_添加"]];
  21. [self addSubview:addView];
  22. [addView mas_makeConstraints:^(MASConstraintMaker *make) {
  23. make.centerX.equalTo(self);
  24. make.top.equalTo(self).offset(40);
  25. make.width.height.mas_equalTo(50);
  26. }];
  27. UILabel *bottomLabel = [UILabel new];
  28. [self addSubview:bottomLabel];
  29. bottomLabel.font = FONT_SIZE(14);
  30. bottomLabel.text = @"到底啦~手下留情喔~";
  31. bottomLabel.textColor = HexColor(@"#CCCCCC");
  32. [bottomLabel mas_makeConstraints:^(MASConstraintMaker *make) {
  33. make.centerX.equalTo(self);
  34. make.bottom.equalTo(self).offset(-40);
  35. make.width.mas_greaterThanOrEqualTo(@60);
  36. make.height.mas_greaterThanOrEqualTo(@40);
  37. }];
  38. }
  39. @end