title: Android ListView onTouchEvent doesn't always give ACTION_DOWN
body: <p>My problem is that when I try to drag an item in my ListView, I don't always get the ACTION_DOWN event. I got lots of ACTION_MOVE events and only one ACTION_UP event.
  It is not always the case. I got ACTION_DOWN 3 times. It confused me.</p>
  
  <p>I looked at similar questions but it's answers seems not fit to mine . Can anyone think of why this is happening?</p>
  
  <p>Thanks</p>
  
  <pre><code>//list_client  --  a listview
  list_client.setOnTouchListener(new View.OnTouchListener() {
      float f1 = -1, f2 = -1 ;
      @Override
      public boolean onTouch(View v, MotionEvent event) {
          switch(event.getAction()){
              case MotionEvent.ACTION_DOWN: 
                  f1 = event.getRawY();
                      break;
              case MotionEvent.ACTION_MOVE:
                  f2 = event.getRawY();
                  if(f2 - f1 &gt; 50){
                      if(View.VISIBLE != rl_search_and_add.getVisbility() &amp;&amp;  ){  rl_search_and_add.setVisibility(View.VISIBLE);
                  }
                  f1 = f2;
                  }else if (f2 - f1 &lt; -50){
                      rl_search_and_add.setVisibility(View.GONE);
                      f1 = f2;
                  }
                  break; 
              case MotionEvent.ACTION_UP:
                  f1 = -1; f2 = -1;
                  break; 
          }
          return false;
      }
  });
  </code></pre>