JSAPI.info

dojo.loaded

Dojo (1.6.1) - see full source
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
dojo.loaded = function(){
    // summary:
    //        signal fired when initial environment and package loading is
    //        complete. You should use dojo.addOnLoad() instead of doing a
    //        direct dojo.connect() to this method in order to handle
    //        initialization tasks that require the environment to be
    //        initialized. In a browser host,    declarative widgets will
    //        be constructed when this function finishes runing.
    d._loadNotifying = true;
    d._postLoad = true;
    var mll = d._loaders;
 
    //Clear listeners so new ones can be added
    //For other xdomain package loads after the initial load.
    d._loaders = [];
 
    for(var x = 0; x < mll.length; x++){
        mll[x]();
    }
 
    d._loadNotifying = false;
    
    //Make sure nothing else got added to the onload queue
    //after this first run. If something did, and we are not waiting for any
    //more inflight resources, run again.
    if(d._postLoad && d._inFlightCount == 0 && mll.length){
        d._callLoaded();
    }
}