1

I am drawing a number of ShapeDrawables through a canvas in a custom android view. I have an onTouchEvent method and it's working fine. Everything is working fine. Now I want to be able to detect if a touch event intersects (i.e. happens inside) a certain ShapeDrawable. Is there a way to do that?

learner
  • 11,490
  • 26
  • 97
  • 169

1 Answers1

2

I got the answer:

  sd.getBounds().contains(x, y)
learner
  • 11,490
  • 26
  • 97
  • 169