Hi,
well ofcourse lots of ways lead to Rome.. trouble is even more ran past it,
into a chasm most likely, but you probably see two types of scenario's that
are most common:
1. your class extends a movieclip
2. your class wraps a movieclip
I dont want to get into a discussion on what the better solution, both cases
are similar.
In your example you have a button.
This button is probably on a screen/view/form whatever.
Commonly you will implement a class for this form. As said either it
subclasses the movieclip containing the button directly (which means you
will have a reference, you'll only need to declare it again in the class to
satisfy the compiler eg
class MyForm extends MovieClip {
}
On 8/10/07, Marcelo Wolfgang <[EMAIL PROTECTED]> wrote:
>
> On 8/10/07, Hans Wichman <[EMAIL PROTECTED]> wrote:
> > Hehe no worries there, I'm sure we all do stuff that causes someone else
> to
> > say they need to kill... etc :)
> > It was meant as a joke nothing harsh to be honest:).
>
> I got it :)
>
> > You are hijacking this thread though, which is in itself ofcourse enough
> > reason to ... :)
>
> Sorry, I was about to ask about this for quite sometime, but I'm too
> f. busy recently and when I saw the joke I had to answer :)
>
>
> > Some answer though:
> > - you dont code AS2 classes on frames, you just write as2 classes in
> files.
> > Once you compile your movie, flash lets you specify in which frame your
> > classes should be exported.
>
> I think what I don't get the most is how do I transform this
>
> function myFunction(){
> return this;
> }
>
> to a class and how I can call it later in something like
>
> btClose_mc.onRelease = myFunction();
>
> i'm thinking in buying moock's essential actionscript 3, but I'm
> afraid it will hard to jump from where I'm now to where the book is.
>
> TIA
> Marcelo Wolfgang
> _______________________________________________
> [email protected]
> To change your subscription options or search the archive:
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
> Brought to you by Fig Leaf Software
> Premier Authorized Adobe Consulting and Training
> http://www.figleaf.com
> http://training.figleaf.com
>
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com