Skip to content

Commit

Permalink
Image, HTML5: Memory issue for IE/Edge.
Browse files Browse the repository at this point in the history
  • Loading branch information
mrsheepuk authored and jayarjo committed Aug 24, 2016
1 parent 65d9b11 commit f51cea4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/javascript/runtime/html5/image/Image.js
Original file line number Diff line number Diff line change
Expand Up @@ -376,6 +376,12 @@ define("moxie/runtime/html5/image/Image", [
_imgInfo.purge();
_imgInfo = null;
}

// Memory issue for IE/Edge. They Keep a reference to image (because of the onload event) and the object not been collected by GC.
if (_img) {
_img.src = '';
}

_binStr = _img = _canvas = _blob = null;
_modified = false;
}
Expand Down

0 comments on commit f51cea4

Please sign in to comment.