diff --git a/EndGate/EndGate.Core.JS/Graphics/ImageSource.js b/EndGate/EndGate.Core.JS/Graphics/ImageSource.js index 167a5454..6d34b51c 100644 --- a/EndGate/EndGate.Core.JS/Graphics/ImageSource.js +++ b/EndGate/EndGate.Core.JS/Graphics/ImageSource.js @@ -40,6 +40,8 @@ var EndGate; this._size = new EndGate.Size2d(width, height); this.ClipLocation = new EndGate.Vector2d(clipX, clipY); this.ClipSize = new EndGate.Size2d(clipWidth, clipHeight); + } else { + this.ClipSize = null; } } Object.defineProperty(ImageSource.prototype, "OnLoaded", { @@ -67,7 +69,7 @@ var EndGate; /** * Determines if the ImageSource has been loaded. */ - ImageSource.prototype.Loaded = function () { + ImageSource.prototype.IsLoaded = function () { return this._loaded; }; diff --git a/EndGate/EndGate.Core.JS/Graphics/ImageSource.ts b/EndGate/EndGate.Core.JS/Graphics/ImageSource.ts index 886b4703..8519d9d7 100644 --- a/EndGate/EndGate.Core.JS/Graphics/ImageSource.ts +++ b/EndGate/EndGate.Core.JS/Graphics/ImageSource.ts @@ -77,6 +77,9 @@ module EndGate.Graphics { this.ClipLocation = new Vector2d(clipX, clipY); this.ClipSize = new Size2d(clipWidth, clipHeight); } + else { + this.ClipSize = null; // Waiting for the image source OnLoad to set it + } } /** @@ -96,7 +99,7 @@ module EndGate.Graphics { /** * Determines if the ImageSource has been loaded. */ - public Loaded(): boolean { + public IsLoaded(): boolean { return this._loaded; }