do you know which ones weren't found (the 3 classes) ?
but Ian, why it find other classes, i dont instantiate any of class,
that code you can see in email is everything, and it has found 15
classes, but 3 doesnt find
Classes found: 15
Classes not found: 3
Why?
On 2/2/06, Ian Thomas <[EMAIL PROTECTED]> wrote:
Hi Franto,
As far as I understand it, 'import' isn't enough to get a class
compiled
into your .swf.
The line:
import sk.sowhat.linuxPlayer.play4dogs.Test;
just tells the compiler that any mention of the word Test in your
code will
refer to that class.
If the class isn't compiled into the SWF, ClassFinder won't find
it. You
actually need to access or instantiate the class somewhere in the
code to
make Flash include it. From memory I think just referring to the
class
constructor is enough e.g.
import sk.sowhat.linuxPlayer.play4dogs.Test;
var dummyVar:Function=sk.sowhat.linuxPlayer.play4dogs.Test; //
somewhere
later in the code
I also have a vague memory that you might be able to force MTASC
to include
classes, but not being a user of MTASC (yet!) I'm not certain on
that one.
HTH,
Ian
P.S.
You may just get away with
import sk.sowhat.linuxPlayer.play4dogs.Test;
sk.sowhat.linuxPlayer.play4dogs.Test; // refers to the
constructor, so Flash
includes the code
I seem to remember reading that somewhere... although
syntactically it's
odd.
On 2/2/06, franto <[EMAIL PROTECTED]> wrote:
Can someone explain me this?
Im using mx.utils.ClassFinder.findClass to find class and make
instance
from it
but some classes it cant find, it's not just problem of
"mx.utils.ClassFinder.findClass" im using another way to create
dynamic class (as I wrote yesterday to the list)
but same classes are not found e.g
sk.sowhat.linuxPlayer.play4dogs.Test
but when I create instance in this way
new sk.sowhat.linuxPlayer.play4dogs.Test()
it is created!!! Can someone tell me why? I try all I know, add
imports and such but nothing
help me. Im stuck on this for 8 hours now :( and i have to find
solution
Please help :)
Maybe you can try it on your own projects, if it will find your
classes
Thank you
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
--
----------------------------------------------------------------------
----------------------------------------------------------------------
---------------------
Franto
http://blog.franto.com
http://www.flashcoders.sk
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders