home *** CD-ROM | disk | FTP | other *** search
/ Neil's C++ Stuff / 2016-02-neilstuff-weebly.iso / apps / audioPlayer2.swf / scripts / __Packages / Loading.as < prev    next >
Encoding:
Text File  |  2016-02-05  |  438 b   |  21 lines

  1. class Loading extends MovieClip
  2. {
  3.    var bar_mc;
  4.    var track_mc;
  5.    function Loading()
  6.    {
  7.       super();
  8.       this.bar_mc._width = 0;
  9.    }
  10.    function update(loaded)
  11.    {
  12.       this.bar_mc._width = Math.round(loaded * this.track_mc._width);
  13.    }
  14.    function resize(newWidth)
  15.    {
  16.       var _loc2_ = newWidth / this.track_mc._width;
  17.       this.track_mc._width = newWidth;
  18.       this.bar_mc._width *= _loc2_;
  19.    }
  20. }
  21.