Changeset 8177

Show
Ignore:
Timestamp:
04/19/07 16:43:27 (21 months ago)
Author:
jburke
Message:

Fixes #2771. An edge case when loading local and remote modules via xd.

Location:
branches/0.4/src
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • branches/0.4/src/hostenv_browser.js

    r7519 r8177  
    273273        } 
    274274 
     275        dojo.hostenv._djInitFired = false; 
    275276        //      BEGIN DOMContentLoaded, from Dean Edwards (http://dean.edwards.name/weblog/2006/06/again/) 
    276277        function dj_load_init(e){ 
     278                dojo.hostenv._djInitFired = true; 
    277279                // allow multiple calls, only first one will take effect 
    278280                // A bug in khtml calls events callbacks for document for event which isnt supported 
  • branches/0.4/src/loader_xd.js

    r8005 r8177  
    541541        //Clear inflight count so we will finally do finish work. 
    542542        this.inFlightCount = 0;  
    543         this.callLoaded(); 
     543         
     544        //Only trigger call loaded if dj_load_init has run. 
     545        if(this._djInitFired && !this.loadNotifying){ 
     546                this.callLoaded(); 
     547        } 
    544548} 
    545549 
     
    574578        if(this.xdHasCalledPreload || dojo.hostenv.getModulePrefix("dojo") == "src" || !this.localesGenerated){ 
    575579                this.xdRealCallLoaded(); 
    576                 this.xdHasCalledPreload = true; 
    577580        }else{ 
    578581                if(this.localesGenerated){ 
     
    583586                        this.preloadLocalizations(); 
    584587                } 
    585                 this.xdHasCalledPreload = true; 
    586         } 
    587 } 
     588        } 
     589        this.xdHasCalledPreload = true; 
     590}