title: How to use on touch listener and on drag listener separately for horizontal scroll view in android?
body: <p>I have a horizontal scroll view where I do an animation of scrolling to end and returning back to start of horizontal scroll view on onTouchListener,but I don't want to do this animation when the user scrolls manually to end.</p>
  
  <pre><code>hv_scroll_radio.setOnTouchListener(new OnTouchListener() {
  
          @Override
          public boolean onTouch(View v, MotionEvent event) {
              ObjectAnimator animator=ObjectAnimator.ofInt(hv_scroll_radio, "scrollX",100);
              animator.setDuration(300);
              animator.start();
  
              new Handler().postDelayed(new Runnable() {
  
                  @Override
                  public void run() {
                      // TODO Auto-generated method stub
                      ObjectAnimator animator=ObjectAnimator.ofInt(hv_scroll_radio, "scrollX",0);
                      animator.setDuration(300);
                      animator.start();
                  }
              }, 1000);
              return false;
          }
      });
  </code></pre>
  
  <p>need help thanks in advance.</p>