Menu

#31 SwfFileLoader

0.9
open
nobody
None
5
2007-03-28
2007-03-28
katopz
No

got problem with this line 227 with flash8+as2lib 0.9.3
-----------------------------------------------------
226 : private function hasFinished(Void):Boolean {
227 : var mc = eval(movieClip._target);
228 : // workaround for a bug of the flash compiler
-----------------------------------------------------
i got "undefined" here so hasFinished function always return "false"

look like "movieClip" is destroy by loadMovie so movieClip._target is gone

then i fixed this by keep _target in var by add this code

//_target
120 : private var _target:String;

//set _target
133 : this._target = movieClip._target

//get _target
var mc = eval(this._target);

all thing work fine now ;)

Discussion

  • katopz

    katopz - 2007-03-28

    SwfFileLoader hasFinished eval undefined fix

     
  • andré

    andré - 2008-10-20

    It seems that the current Flash Compiler (Flash CS3) doesn't have this bug anymore.
    So I simply commented out the workaround and it worked:

    So the fix goes like this:
    ...
    221 private function hasFinished(Void):Boolean {
    222 // var mc = eval(movieClip._target);
    223 // workaround for a bug of the flash compiler
    224 // movieClip = mc;
    ...

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.