Hi Ian 

I'm in full agreement with you - mouseChildren = false is the best generic 
solution. 

There are a couple of situations where you might not be able to use it. For 
example if you have a complex button behaviour situation that for some strange 
reason has some weird animation that gets triggered off of rolling over a child 
of the button and thus the child needs access to the mouse. 

But in that case, if memory serves me right, I would put a trap in the parent 
level that simply catches the child mouse event, calling 
stopImmediatePropogation() and then redispatching the same event on the parent 
with bubbles set to true. This alters the target to be the parent but allows 
the child to maintain its interactive functionality. It acts like mouseChildren 
= false. 

Why designers like to design features like this is beyond me, but hey it 
happens. 

Sincerely 
Mark R. Jonkman 


----- Original Message ----- 
From: "Ian Thomas" <[email protected]> 
To: "Flash Coders List" <[email protected]> 
Sent: Thursday, November 19, 2009 4:27:24 PM GMT -05:00 US/Canada Eastern 
Subject: Re: [Flashcoders] AS3 mouseUpOutside not working, yuck! 

What? mouseChildren=false always works, whether the job is simple or 
not. That's what it was designed for! 

Ian 

On Thu, Nov 19, 2009 at 9:19 PM, Henrik Andersson <[email protected]> 
wrote: 
> Ian Thomas wrote: 
>> 
>> Henrik, 
>> Setting mouseChildren=false on an InteractiveObject/Sprite is much 
>> easier. The children no longer react to or originate mouse events. 
> 
> Agreed, it is easier. But the loop always works. I don't use it for simple 
> cases. The right tool for the right job. 
> 
> _______________________________________________ 
> Flashcoders mailing list 
> [email protected] 
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders 
> 

_______________________________________________ 
Flashcoders mailing list 
[email protected] 
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders 
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to