Scroller应用:ListView滑动删除(三)

2015-07-20 17:46:09 · 作者: · 浏览: 20
OVE: Log.e(test, isIntercept ACTION_MOVE +isLock); if (!isLock) { float deltaX = Math.abs(mLastMotionX - x); float deltay = Math.abs(mLastMotionY - y); mLastMotionX = x; mLastMotionY = y; if (deltaX > deltay && deltaX > minDis) { isLock = true; return false; } } else { return false; } break; case MotionEvent.ACTION_UP: Log.e(test, isIntercept ACTION_UP +isLock); isLock = false; break; case MotionEvent.ACTION_CANCEL: Log.e(test, isIntercept ACTION_CANCEL +isLock); isLock = false; break; } return true; } }

?

5、XML代码

?

?


  
    
     
    
   

    
   
    
    
   
  

6、界面效果

/

?

?