Android:如何用手指推出屏幕的ImageView?

时间:2012-08-24 21:02:38

标签: android eclipse android-imageview ontouchlistener

我正在寻找一种用手指(任何方向)移动ImageView的方法,当ImageView移出屏幕时,这个消失,然后在屏幕中间出现一个新的。 p>

你知道我能做哪个库吗?

1 个答案:

答案 0 :(得分:0)

它必须是ImageView吗?

您可以在画布上绘制一个位图,并根据用户触摸的位置更改其坐标,然后检查x< 0或x> canvas.getWidth()或y< 0或y> canvas.getHeight()

这是其他人的例子: Touch and drag image in android