MWPhotoBrowser, simple and elegant image library for iOS
来源:互联网 发布:程序员转正答辩ppt 编辑:程序博客网 时间:2024/05/21 17:08
MWPhotoBrowser, simple and elegant image library for iOS
When it’s necessary a gallery within an app for iOS, we can find already developed several solutions that can help us in the project. After studying various options, from Sixtemia we recommend the solution developed by Michael Waterfall (Milton Keynes, UK) MWPhotoBrowser.
The strengths of the library are:
- Easy to integrate in our project.
- Updated to iOS7.
- Load images with local or remote with cache.
- Ability to show a picture text label.
- Selection of images and touch to capture the image.
- Share options.
Below is an example of how to integrate the library:
// Create array of MWPhoto objects
[photos addObject:[MWPhoto photoWithURL:[NSURL fileURLWithPath:[[NSBundlemainBundle] pathForResource:@"photo2l" ofType:@"jpg"]]]];
[photos addObject:[MWPhoto photoWithURL:[NSURL URLWithString:@"http://farm4.static.flickr.com/3629/3339128908_7aecabc34b.jpg"]]];
[photos addObject:[MWPhoto photoWithURL:[NSURL URLWithString:@"http://farm4.static.flickr.com/3590/3329114220_5fbc5bc92b.jpg"]]];
// Create browser (must be done each time photo browser is
// displayed. Photo browser objects cannot be re-used)
MWPhotoBrowser*browser=[[MWPhotoBrowseralloc] initWithDelegate:self];
// Set options
browser.displayActionButton=YES;// Show action button to allow sharing, copying, etc (defaults to YES)
browser.displayNavArrows=NO;// Whether to display left and right nav arrows on toolbar (defaults to NO)
browser.displaySelectionButtons=NO;// Whether selection buttons are shown on each image (defaults to NO)
browser.zoomPhotosToFill=YES;// Images that almost fill the screen will be initially zoomed to fill (defaults to YES)
browser.alwaysShowControls=NO;// Allows to control whether the bars and controls are always visible or whether they fade away to show the photo full (defaults to NO)
browser.enableGrid=YES;// Whether to allow the viewing of all the photo thumbnails on a grid (defaults to YES)
browser.startOnGrid=NO;// Whether to start on the grid of thumbnails instead of the first photo (defaults to NO)
browser.wantsFullScreenLayout=YES;// iOS 5 & 6 only: Decide if you want the photo browser full screen, i.e. whether the status bar is affected (defaults to YES)
// Optionally set the current visible photo before displaying
[browser setCurrentPhotoIndex:1];
// Present
[self.navigationController pushViewController:browser animated:YES];
// Manipulate
[browser showNextPhotoAnimated:YES];
[browser showPreviousPhotoAnimated:YES];
[browser setCurrentPhotoIndex:10];
The library is based on two methods of its delegate to assign images to the gallery:
- MWPhotoBrowser, simple and elegant image library for iOS
- Simple Image process library
- A powerful image downloading and caching library for Android
- Picasso-A powerful image downloading and caching library for Android
- Simple OpenGL Image Library(soil纹理库)
- nostra13---Universal Image Loader(Powerful and flexible library for loading, caching and displaying)
- CLISP is so elegant simple and systematic as well as C
- HJCache: iPhone cache library for asynchronous image loading and caching(上)
- Zip Utils - clean, elegant, simple, C++/Win32
- IOS Icon and Image Sizes
- iOS Icon and Image Sizes
- Simple Numeric Pagination for DataList and Repeater
- Useful and Simple srcipts for Oracle CoolBackup
- Useful and Simple srcipts for Oracle CoolBackup
- Pushy is a Java library for sending APNs (iOS and OS X) push notifications
- A Simple C# Wrapper for the AviFile Library
- PCANet: A Simple Deep Learning Baseline for Image Classification?(精读)
- 《PCANet: A Simple Deep Learning Baseline for Image Classification》
- OnRowDeleting事件和OnRowCommand事件之间的触发关系
- array_merge() 函数
- 检查Gemfile.lock,存在内存泄露的gem包,请及时更新
- iOS Runtime详解之SEL,Class,id,IMP,_cmd,isa,method,Ivar
- java应用技术 3(2)
- MWPhotoBrowser, simple and elegant image library for iOS
- 2015/11/6 IOS9适配
- Dzmitry Urbanovich领跑2015 WSOPE柏林站主赛事Day2
- Springmvc 原理
- java应用技术 3(3)
- android基础之drawable
- haproxy 教程 -转载
- Linux下Oracle安装文件.cpio.gz文件的解压
- java中类的卸载