One of my custom components extends the Canvas and has a button on it.
 Both the canvas and button are rigged to activate seperate functions
when clicked.  I've called them canvasClicked() and buttonClicked().

Now, clicking on the canvas where the button isn't triggers the
canvasClicked() function, as planned.  However, clicking on the
button, which is within the Canvas region, appears to trigger both
canvasClicked() and buttonClicked().

The hack-y way I thought of to make sure that only buttonClicked()
actually does anything is to introduce a semaphore-like mechanism to
both functions (that is, buttonClicked() sets a flag to true; do
canvasClicked() only if flag is false).  But there must be a better
way to handle this.  Anyone know what it is?  Thanks.





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to