if(typeof KAJONA=="undefined"){var KAJONA={util:{},portal:{lang:{}},admin:{lang:{}}}}KAJONA.util.Loader=function(){var g=[];var f=[];var c=[];function e(){for(var l=0;l<g.length;l++){if(g[l]){var k=true;for(var h=0;h<g[l].requiredModules.length;h++){if($.inArray(g[l].requiredModules[h],f)==-1){k=false;break}}if(k){g[l].callback();delete g[l]}}}}this.loadFile=function(h,k,l){var j=[];if(!$.isArray(h)){h=[h]}$.each(h,function(n,m){if($.inArray(m,f)==-1){j.push(m)}});if(j.length==0){if($.isFunction(k)){k()}}else{var i=false;$.each(j,function(o,n){var m=n.substr(n.length-2,2)=="js"?"js":"css";if(!i&&$.isFunction(k)){g.push({callback:function(){setTimeout(k,100)},requiredModules:j});i=true}if($.inArray(n,c)==-1){c.push(n);if(m=="css"){d(b(n,l),n)}if(m=="js"){a(b(n,l),n)}}})}};function b(i,h){if(!h){i=KAJONA_WEBPATH+i}i=i+"?"+KAJONA_BROWSER_CACHEBUSTER;return i}function d(i,h){if(document.createStyleSheet){document.createStyleSheet(i)}else{$('<link rel="stylesheet" type="text/css" href="'+i+'" />').appendTo("head")}f.push(h);e()}function a(j,i){var h={dataType:"script",cache:true,url:j};$.ajax(h).done(function(k,l){f.push(i);e()}).fail(function(m,l,k){})}};