Thank you all guys! Great job.
But I still have something to ask, silly or not. One thing eval does for me
and I don't know if I'm right or wrong, is when I use it (despite I know
it's not the better solution), it let's me leave my function like this:
_anywhere.rew(mcToRewind, whenDoneRewindingNewAction);
ˆ path.MC ˆ same path of mcToRewind
Why this is matter to me? Because I don't have to treat the scope as a
parameter and I can keep my function easy to use for any newbie/flash
designer (that is really important to me). So nobody doesn't have to think
about scope stuff and anybody can use it as was using a very common
function. Which using your code they have to think about scope, putting all
the path as a different parameter.
In Jesse's third example we could just drop the scope parameter. However,
it's always treating the scope from where the function is. While this is
perfectly right and understandable for me I think a newbie would spend I
time to understand what's going on.
If I've been nagging to much or the real stupid one, we can just drop the
subject, and stick to your solutions. = P
On 19/02/07, T. Michael Keesey <[EMAIL PROTECTED]> wrote:
On 2/18/07, Jesse Graupmann <[EMAIL PROTECTED]> wrote:
> var callback:Function = mx.utils.Delegate.create ( _root, nextFrame );
> anyOtherObject.func = function(){ callback () };
> anyOtherObject.func ();
You can combine the first two lines (and simplify the second) to just:
anyOtherObj.func = mx.utils.Delegate.create(_root, nextFrame);
No need for the inline function.
--
Mike Keesey
_______________________________________________
[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