Search the web
Sign In
New User? Sign Up
canvas-developers · Canvas Developers
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Want to share photos of your group with the world? Add a group photo to Flickr.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Best way to allow for clicks? Collision detection? Events?   Message List  
Reply | Forward Message #464 of 493 |
If I have ui elements in a canvas that I want to be clickable - what
is the best way to go about doing that? Do I need to create some kind
of collision detection to see if the mouse x,y is in a region? Or is
there some better way?






Wed Nov 12, 2008 3:59 pm

triptych999
Offline Offline
Send Email Send Email

Forward
Message #464 of 493 |
Expand Messages Author Sort by Date

If I have ui elements in a canvas that I want to be clickable - what is the best way to go about doing that? Do I need to create some kind of collision...
Andrew
triptych999
Offline Send Email
Nov 12, 2008
3:59 pm

... You can: 1. Attach a function to the canvas onclick event 2. Get the mouse coords from the resultant event object. 3. Those, combined with some magic, will...
Richard Heyes
richard.heyes@...
Send Email
Nov 12, 2008
5:48 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help