문제

I have a custom layout that I have written that basically just displays a bunch of ImageViews. I am handing onTouch events for all the ImageViews in my layout.

However, if a user touches one imageView and then drags over another ImageView, I would like to be able to handle that as well.

How would I go about capturing this behaviour?

도움이 되었습니까?

해결책

maybe this example is useful: http://www.anddev.org/viewtopic.php?p=11603

it relies on tracking the event with MotionEvent.ACTION_MOVE. the coordinates could be checked to determine when the element enters/exits a cell.

it uses drawview, but hopefully the same can be done w/imageview

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top