AS3: Handle Preloaders in ie7


/ Published in: ActionScript 3
Save to your folder(s)

As always, IE7 is stupid


Copy this code and paste it in your HTML
  1. this.addEventListener("enterFrame",onEnterFrame);
  2.  
  3. function onEnterFrame(e:Event) {
  4. loadbar.width = (this.loaderInfo.bytesLoaded/this.loaderInfo.bytesTotal)*200;
  5. if (this.loaderInfo.bytesLoaded == this.loaderInfo.bytesTotal) {
  6. gotoAndPlay(2);
  7. this.removeEventListener("enterFrame", onEnterFrame);
  8. }
  9. }

URL: http://blog.hydrotik.com/2007/10/01/as3-useful-little-things/

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.