一款简洁实用方便的相册图片浏览器
因为项目中经常要用到图片浏览器,所以最近利用空闲时间做了一款简洁的相册图片浏览器,支持浏览图片,视频,兼容ios7。地址:https://github.com/shushaoyong/SYPhotoBrowser
下面是示例代码:
使用方法 1.展示图片 SYPhotoGroupViewController *vc = [[SYPhotoGroupViewController alloc] init]; vc.videoEnabled = NO; vc.didFinishcompletionBlock = ^(NSArray *items) { NSLog(@"选择的图片:%@",items); }; UINavigationController *nav = [[UINavigationController alloc] initWithRootViewController:vc]; [self presentViewController:nav animated:YES completion:nil]; 2.展示视频 SYPhotoGroupViewController *vc = [[SYPhotoGroupViewController alloc] init]; vc.videoEnabled = YES; vc.didFinishcompletionBlock = ^(NSArray *items) { NSLog(@"选择的视频:%@",items); }; UINavigationController *nav = [[UINavigationController alloc] initWithRootViewController:vc]; [self presentViewController:nav animated:YES completion:nil];
更多效果 请进入github查看:
地址:https://github.com/shushaoyong/SYPhotoBrowser