Worked around initConnection() failures due to machines that initialize more slowly, by also allowing each machine to invoke the other's initConnection(); if it turns out to be unnecessary, it's simply ignored
This commit is contained in:
parent
8dcc9df293
commit
983651610c
14 changed files with 1035 additions and 937 deletions
|
|
@ -226,17 +226,9 @@ Component.subclass = function(subclass, superclass, methods, statics)
|
|||
* various resources used by that machine.
|
||||
*/
|
||||
if (window) {
|
||||
if (!window['PCjs']) {
|
||||
window['PCjs'] = {
|
||||
'Machines': {},
|
||||
'Components': []
|
||||
};
|
||||
}
|
||||
/*
|
||||
* Alias the new global objects above to their original property names, to minimize code changes.
|
||||
*/
|
||||
Component.machines = window['PCjs']['Machines'];
|
||||
Component.components = window['PCjs']['Components'];
|
||||
if (!window['PCjs']) window['PCjs'] = {};
|
||||
Component.machines = window['PCjs']['Machines'] || (window['PCjs']['Machines'] = {});
|
||||
Component.components = window['PCjs']['Components'] || (window['PCjs']['Components'] = []);
|
||||
}
|
||||
else {
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue