您的位置:首页 > 其它

[2015-03-18]关于MWPhotoBrowser在…

2015-06-26 09:21 148 查看
在 MWZoomingScrollView.m 下

1) 在此方法下 - (id)initWithPhotoBrowser:(MWPhotoBrowser
*)browser:

加入 self.scrollEnabled =
false;

2) 在下面方法-
(void)scrollViewWillBeginZooming:(UIScrollView *)scrollView
withView:(UIView *)view 中
把 scrollEnabled
= YES
替换成

if
(self.zoomScale > 1.0f) { // check if it is zoomed in

self.scrollEnabled = NO;

}

else {

self.scrollEnabled = YES; // reset

}

- (void)scrollViewWillBeginZooming:(UIScrollView *)scrollView
withView:(UIView *)view {

//self.scrollEnabled = YES; // reset

if (self.zoomScale > 1.0f) { // check if it is zoomed
in
self.scrollEnabled
= NO;
}

else
{
self.scrollEnabled
= YES; // reset
}

[_photoBrowser
cancelControlHiding];
}

完美解决此方法。详见https://github.com/mwaterfall/MWPhotoBrowser/issues/309
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: