I wanted to know if it's possible to find out the current target in touch event. Consider a scenario where you have multiple tiles and the user is sliding over them. You need to find at the point of movement which tile is the user over. Ofcouse we can do it with the set of cordinates given out by touchevent but it would be great if I knew directly the current target I'm moving over. Is there any way to get it?
Touchevent's current target(4 posts) (2 voices)
You mean the object that the finger is actually touching at that moment, right? Even though the touch began on another object.
Sorry, no, there's no way to get that at the moment except calculating it yourself, using the "hitTest" method or custom logic.
Yeah, seems like I'll have to go the custom way. Thanks for the prompt reply.
But if that could be added that'd be great for tile based swipe stuff.
Thanks for the suggestion -- I'll think about ways to make this easier!
You must log in to post.