SDPhotoBrowser
SDPhotoBrowser copied to clipboard
A image browser which is easy for using.
1.如果photos是collectionView的情况下,在collectionView复用、或者collectionView用删除添加操作的话,通过subViews去取sourceView的时候,是存在问题的。 建议可以添加一个代理方法:专门返回当前点击的子View,我改了一下,测试了几台机器,还是很好用的。请楼主采纳 添加的代理方法: - (UIView *)photoBrowserGetCurrentViewWithIndex:(NSInteger)index; 获取当前子View代理方法: UIView *sourceView = self.sourceImagesContainerView.subviews[self.currentImageIndex]; if ([self.delegate respondsToSelector:@selector(photoBrowserGetCurrentViewWithIndex:)]){ sourceView = [self.delegate photoBrowserGetCurrentViewWithIndex:self.currentImageIndex]; } 代理实现 - (UIView *)photoBrowserGetCurrentViewWithIndex:(NSInteger)index { NSIndexPath *indexPath = [NSIndexPath indexPathForRow:index inSection:0];...
目前在自用以及商用~感谢!
本地图片不支持吗?
用手机照的图片放大会变形,变成长条形
点击图片 放大 的过程不够流畅 ,放大后 再点击 会回到当前图片的位置 这个过程也不是很流畅 有点卡顿延迟的感觉.过程好像有闪烁
我在你的Demo里设置了 contentMode 40行 动画最后会闪一下才变回原来的frame 请问有什么好的解决方案。 [photoItemArray enumerateObjectsUsingBlock:^(SDPhotoItem *obj, NSUInteger idx, BOOL *stop) { UIButton *btn = [[UIButton alloc] init]; [btn sd_setImageWithURL:[NSURL URLWithString:obj.thumbnail_pic] forState:UIControlStateNormal]; btn.imageView.contentMode = UIViewContentModeScaleAspectFill; btn.tag = idx; [btn...
`SDPhotoBrowser.m`文件的`- (void)photoClick:(UITapGestureRecognizer *)recognizer`方法里面的这句`UIView *sourceView = self.sourceImagesContainerView.subviews[currentIndex];`数据越界,各位有好的方案吗?
你好,使用框架时候,例如我有6张图片,点击进去一直拖动,拖动到第6张的时候,会出现数组越界的情况,导致程序cash,请问这个容错处理是该怎么解决的.