UIScrollview

1.UIScrollview与Autolayout
make.bottom.mas_equalTo(self.contentScrollView); 主要是要计算出contentsize。

 UIView *bannerView=[[UIView alloc] init];
 
 [self.contentScrollView  addSubview:bannerView];
 
 [bannerView mas_makeConstraints:^(MASConstraintMaker *make) {
     
     make.left.mas_equalTo(self.contentScrollView);
     make.top.mas_equalTo(NAVBAR_HIGHT);
     make.width.mas_equalTo(self.contentScrollView);
     make.height.mas_equalTo(1000);
     make.bottom.mas_equalTo(self.contentScrollView);   //这个
     
 }];

你可能感兴趣的:(UIScrollview)