Return to Snippet

Revision: 23473
at February 8, 2010 11:45 by espinallab


Initial Code
[[AsyncImageCache shared] loadImageForURL:updateAnnotation.profileImageURL delegate:self];


//---------------------------------------------------------------------
// AsyncImageCache Delegate
//---------------------------------------------------------------------

- (void)asyncImageCacheLoadedImage:(UIImage *)image forURL:(NSString *)url
{
	// just in case
	[twitterUserIcon release];
	twitterUserIcon = nil;

	// remember this image, if it corresponds to the expected URL
	UpdateAnnotation *updateAnnotation = (UpdateAnnotation *) self.annotation;
	if (image != nil && [url isEqualToString:updateAnnotation.profileImageURL])
	{
		twitterUserIcon = [image retain];
		[self fadeInNewUserIcon];
	}

	// force full redraw
	[self setNeedsDisplay];
}

Initial URL

                                

Initial Description

                                

Initial Title
Async Images Code

Initial Tags

                                

Initial Language
Objective C