/TitaniumCachedImageView

Quick function for caching remote images in Appcelerator Titanium. Works on Titanium SDK 1.4.0+

Primary LanguageJavaScriptOtherNOASSERTION

Developed by Kevin L. Hopkins ( personal site or Found Design + Interactive ) You may borrow, steal, use this in any way you feel necessary but please leave attribution to me as the source. If you feel especially grateful, give me a linkback from your blog, a shoutout @Devneck on Twitter, or my company profile @ http://wearefound.com.

For Titanium Mobile - cachedImageView.js


For more, head out to my site or to the Appcelerator Developer Center.

Android and iOS Users:


Implementation works the same cross-platform. Enjoy!

Questions?


If you have any questions, please feel free to ask on my blog or via the contact information found there.

Usage:


cachedImageView Usage:

Ti.include('lib/cachedImageView.js');
function createMyImage() {
	var win = Ti.UI.currentWindow;

	var imgMyImage = Ti.UI.createImageView({
		width: 120,
		height: 120,
		top:10,
                    left:10
	});

	cachedImageView('imageDirectoryName', 'http://MyRemoteServer.com/public/images/1.png', imgMyImage);

	win.add(imgMyImage);
	win.open({animated:true});
};

License:


Copyright © 2011 Kevin L. Hopkins. It is free software, and may be redistributed under the terms specified in the LICENSE file.