Markdown Test

- (void)scrollViewDidZoom:(UIScrollView *)scrollView{
    for (UIView *subview in scrollView.subviews){
        CGFloat offsetX = (scrollView.bounds.size.width > scrollView.contentSize.width)?(scrollView.bounds.size.width - scrollView.contentSize.width)/2 : 0.0;
        CGFloat offsetY = (scrollView.bounds.size.height > scrollView.contentSize.height)?(scrollView.bounds.size.height - scrollView.contentSize.height)/2 : 0.0;
        subview.center = CGPointMake(scrollView.contentSize.width/2 + offsetX,scrollView.contentSize.height/2 + offsetY);
        }
    }

只能说我认了
百度是用来测网络的

你可能感兴趣的:(Markdown Test)