CanvasScript3
>
Tests
> Loader - Load
Code
var stage = new Stage("canvas", 420, 500, 30); var loader = new Loader(); loader.contentLoaderInfo.addEventListener(Event.COMPLETE, function(e) { trace('loaded'); }); loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, function(e) { trace('error'); }); loader.load(new URLRequest('img/photo01.jpg')); stage.addChild(loader);
Canvas
Output