(function(a){a.lazy=function(e){if(typeof e.name=="string")e.name=[e.name];a.each(e.name,function(n){function s(b,c,f,d,i){a.lazy.archive[b].status="loading";var g=document.createElement("link");g.type="text/css";g.rel="stylesheet";g.href=b;g.media="screen";document.getElementsByTagName("head")[0].appendChild(g);a.lazy.archive[b].status="loaded";c&&c(f,d,i)}function p(b,c,f,d,i){a.lazy.archive[b].status="loading";a.ajax({type:"GET",url:b,cache:t,dataType:"script",success:function(){a.lazy.archive[b].status=
"loaded";c&&c(f,d,i)}})}function o(b,c,f){p(h,function(){if(typeof b=="object")f.length>0?a(b)[c].apply(b,f):a(b)[c]();else a[c].apply(null,f);a.each(a.lazy.archive[h].que,function(d){d=a.lazy.archive[h].que[d];m[d.name].apply(d.self,d.arguments)});a.lazy.archive[h].que=[]},b,c,f)}var h=e.src,j=e.name[n],t=e.cache||true;n=e.isFunction||true;var u=e.isMethod||true,k,m={};a.lazy.archive[h]={status:"unloaded",que:[]};m[j]=function(){var b=this;k=arguments;if(a.lazy.archive[h].status==="loaded")a.each(this,
function(){a(this)[j].apply(b,k)});else if(a.lazy.archive[h].status==="loading")a.lazy.archive[h].que.push({name:j,self:b,arguments:k});else{a.lazy.archive[h].status="loading";if(e.dependencies){var c=e.dependencies.css||[],f=e.dependencies.js||[],d=c.length+f.length,i=function(g,q){var r=g.length,l;for(g=g.reverse();r--&&d--;){l=g[r];if(typeof a.lazy.archive[l]=="undefined")a.lazy.archive[l]={status:"unloaded",que:[]};if(a.lazy.archive[l].status==="unloaded")d?q(l):q(l,function(){o(b,j,k)});else d||
o(b,j,k)}};i(c,s);i(f,p)}else o(b,j,k)}return this};u&&jQuery.fn.extend(m);n&&jQuery.extend(m)})};a.lazy.archive={}})(jQuery);