开发者

Install enormego's PhotoViewer for use in app

开发者 https://www.devze.com 2023-03-31 00:30 出处:网络
How do you install PhotoViewer found athttps://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 \"EGOImageLo

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

精彩评论

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

关注公众号