解决方案 »
- Gif的内存溢出
- 请教:ListView设置adapter之后,不走adapter的getView方法
- android大量定时问题
- android 不同activity中怎么传递参数,又不开启新的activity
- android2.2开发时在eclipse的file explorer视图中不显示手机的sdcard信息
- jni开发中用到的so文件用户怎么安装?
- AIDL,调用远程服务的进程被挂掉,以及被不同进程多次连接,远程服务端的进程如何获知?
- tab中使用selector无法更改背景
- android 里的后台服务中想显示对话框,怎么实现?
- 关于android robotium
- 【诚心请教】Android超时导致数据与服务器不同步
- MyEclipse配置web项目无法访问
public boolean onInterceptTouchEvent(MotionEvent ev) {
mGestureDetector.onTouchEvent(ev);
return false;
}private class MyGestureDetector extends GestureDetector.SimpleOnGestureListener {
@Override
public boolean onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY){
//在这里获取距离
}
}mGestureDetector = new GestureDetector(mContext.getApplicationContext(),
new MyGestureDetector(), null, false);
onTouchEvent方法也不错。