Android: custom view onClickEvent with X & Y locations

后端 未结 6 647
你的背包
你的背包 2020-12-21 15:12

I\'ve got a custom view and I want to get the X and Y coordinates of a user click. I\'ve found that I can only get the coordinates from the onTouchEvent and an onClickEvent

6条回答
  •  星月不相逢
    2020-12-21 15:35

    i think you have to call super.onTouchEvent(event) because in that method, the click is detected.

提交回复
热议问题