var ImagePreloader = Class.create();
ImagePreloader.prototype = {
	initialize: function(imageSrc, callback) {
		this.imageSrc=imageSrc;
		this.callback=callback;
		this.image = new Image();
		this.image.onload = this.__onComplete.bind(this);
		this.image.src=imageSrc;
	},

	__onComplete: function() {
		this.callback(this);
	}
};


