housekeeping for delayed instance
parent
d2b3c7bf4c
commit
743e45b0f0
|
@ -119,6 +119,13 @@ GameLib.Component.prototype.createInstance = function() {
|
||||||
|
|
||||||
console.log('create instance : '+ this.name);
|
console.log('create instance : '+ this.name);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* When you do actually call 'createInstance' - it is wise to state we are no longer delayed - we assume the caller
|
||||||
|
* knows when to call createInstance, so we do the housekeeping here
|
||||||
|
* @type {boolean}
|
||||||
|
*/
|
||||||
|
this.delayed = false;
|
||||||
|
|
||||||
if (this.instance) {
|
if (this.instance) {
|
||||||
|
|
||||||
this.loaded = true;
|
this.loaded = true;
|
||||||
|
|
|
@ -164,7 +164,6 @@ GameLib.System.Input.prototype.start = function() {
|
||||||
false
|
false
|
||||||
);
|
);
|
||||||
|
|
||||||
editorControl.delayed = false;
|
|
||||||
editorControl.createInstance();
|
editorControl.createInstance();
|
||||||
|
|
||||||
editorControl.domElement.instance.addEventListener(
|
editorControl.domElement.instance.addEventListener(
|
||||||
|
|
|
@ -1005,8 +1005,6 @@ GameLib.System.Storage.prototype.loadImage = function(data) {
|
||||||
|
|
||||||
image.instance = img;
|
image.instance = img;
|
||||||
|
|
||||||
image.delayed = false;
|
|
||||||
|
|
||||||
image.createInstance();
|
image.createInstance();
|
||||||
|
|
||||||
if (onLoaded) {
|
if (onLoaded) {
|
||||||
|
|
Loading…
Reference in New Issue