开发者

Install enormego's PhotoViewer for use in app

How do you install PhotoViewer found at https://gi开发者_JS百科thub.com/enormego/PhotoViewer? I have it downloaded I just don't know what to put into my app.


Drag and drop "EGOCache" and "EGOImageLoader" folders from the demo project into your project.Add "MessageUI.framework" into your project.

Then you can use the following code as in the demo.(instead of MyPhoto and MyPhotoSource class, we should use EGOQuickPhoto and EGOQuickPhotoSource ).Dats all....!!

        EGOQuickPhoto *photo = [[EGOQuickPhoto alloc] initWithImageURL:[NSURL URLWithString:@"http://a3.twimg.com/profile_images/66601193/cactus.jpg"] name:@" laksd;lkas;dlkaslkd ;a"];
        EGOQuickPhoto *photo2 = [[EGOQuickPhoto alloc] initWithImageURL:[NSURL URLWithString:@"https://s3.amazonaws.com/twitter_production/profile_images/425948730/DF-Star-Logo.png"] name:@"lskdjf lksjdhfk jsdfh ksjdhf sjdhf ksjdhf ksdjfh ksdjh skdjfh skdfjh "];
        EGOQuickPhotoSource *source = [[EGOQuickPhotoSource alloc] initWithPhotos:[NSArray arrayWithObjects:photo, photo2, photo, photo2, photo, photo2, photo, photo2, nil]];

        EGOPhotoViewController *photoController = [[EGOPhotoViewController alloc] initWithPhotoSource:source];
        [self.navigationController pushViewController:photoController animated:YES];

        [photoController release];
        [photo release];
        [photo2 release];
        [source release]; 
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜