//mootools more, . copyright (c) 2006-2009 aaron newton , valerio proietti & the mootools team , mit style license. mootools.more={version:"1.2.3.1"};var asset={javascript:function(f,d){d=$extend({onload:$empty,document:document,check:$lambda(true)},d);var b=new element("script",{src:f,type:"text/javascript"}); var e=d.onload.bind(b),a=d.check,g=d.document;delete d.onload;delete d.check;delete d.document;b.addevents({load:e,readystatechange:function(){if(["loaded","complete"].contains(this.readystate)){e(); }}}).set(d);if(browser.engine.webkit419){var c=(function(){if(!$try(a)){return;}$clear(c);e();}).periodical(50);}return b.inject(g.head);},css:function(b,a){return new element("link",$merge({rel:"stylesheet",media:"screen",type:"text/css",href:b},a)).inject(document.head); },image:function(c,b){b=$merge({onload:$empty,onabort:$empty,onerror:$empty},b);var d=new image();var a=document.id(d)||new element("img");["load","abort","error"].each(function(e){var f="on"+e; var g=b[f];delete b[f];d[f]=function(){if(!d){return;}if(!a.parentnode){a.width=d.width;a.height=d.height;}d=d.onload=d.onabort=d.onerror=null;g.delay(1,a,a); a.fireevent(e,a,1);};});d.src=a.src=c;if(d&&d.complete){d.onload.delay(1);}return a.set(b);},images:function(d,c){c=$merge({oncomplete:$empty,onprogress:$empty,onerror:$empty,properties:{}},c); d=$splat(d);var a=[];var b=0;return new elements(d.map(function(e){return asset.image(e,$extend(c.properties,{onload:function(){c.onprogress.call(this,b,d.indexof(e)); b++;if(b==d.length){c.oncomplete();}},onerror:function(){c.onerror.call(this,b,d.indexof(e));b++;if(b==d.length){c.oncomplete();}}}));}));}};