Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 27 additions & 5 deletions build/director.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@


//
// Generated on Fri Dec 27 2013 12:02:11 GMT-0500 (EST) by Nodejitsu, Inc (Using Codesurgeon).
// Version 1.2.2
// Generated on Thu Jun 26 2014 10:43:17 GMT+0100 (BST) by Nodejitsu, Inc (Using Codesurgeon).
// Version 1.2.3
//

(function (exports) {
Expand Down Expand Up @@ -86,10 +86,32 @@ var listener = {
// upon initial page load. Since the handler is run manually in init(),
// this would cause Chrome to run it twise. Currently the only
// workaround seems to be to set the handler after the initial page load
// We then need to keep track of outstanding fire requests
// http://code.google.com/p/chromium/issues/detail?id=63040
setTimeout(function() {
window.onpopstate = onchange;
}, 500);
var fireOnReady = false;
var fire = this.fire;
this.fire = function() {
fireOnReady = true;
};
var onDOMReady = function() {
setTimeout(function() {
self.fire = fire;
window.onpopstate = onchange;
if (fireOnReady) {
self.fire();
}
}, 1)
};

if(document.readyState === 'complete') {
onDOMReady();
}
else if (window.addEventListener) {
window.addEventListener('load', onDOMReady, false);
}
else if (window.attachEvent) {
window.attachEvent('onload', onDOMReady);
}
}
else {
window.onhashchange = onchange;
Expand Down
Loading