Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6124775
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T16:10:17+00:00 2026-05-23T16:10:17+00:00

Ok, so I have this setup ScrollView HorizontalScrollView ImageView I am trying to capture

  • 0

Ok, so I have this setup

ScrollView
HorizontalScrollView
ImageView

I am trying to capture the doubleTap on the Image View.. my code looks like the following:

ImageView iv = (ImageView)findViewById(R.id.ImageViewID);

iv.setImageDrawable(iv.getResources().getDrawable(R.drawable.someimage));
// Gesture detection
detector = new GestureDetector(this,new SimpleOnGestureListener(){

    //new myGestureClass());

    @Override
    public boolean onSingleTapUp(MotionEvent e) {
        // TODO Auto-generated method stub
        System.out.println("SINGLE TAP");
        return false;
    }

    @Override
    public boolean onDoubleTap(MotionEvent arg0) {
        // TODO Auto-generated method stub
        System.out.println("DOUBLE TAP");
        return false;
    }

    @Override
    public boolean onDoubleTapEvent(MotionEvent arg0) {
        // TODO Auto-generated method stub
        System.out.println("DOUBLE TAP EVENT");
        return false;
    }

    @Override
    public boolean onSingleTapConfirmed(MotionEvent arg0) {
        // TODO Auto-generated method stub
        return false;
    }

});

View.OnTouchListener gestureListener = new View.OnTouchListener() {
        public boolean onTouch(View v, MotionEvent event) {
        System.out.println("TOUCH!" +event);
        if (detector.onTouchEvent(event)) {
            return true;                 
        }   
        return false;
        }
    };

iv.setOnTouchListener(gestureListener); 

Yet the overridden tap methods never get called… The onTouch does get called but the detector.onTouchEvent(event) that should be tying my events to the touch event, never ever calls my overRidden methods…. So, what the heck am I am doing wrong?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T16:10:17+00:00Added an answer on May 23, 2026 at 4:10 pm

    Override onDown method and return true. Source

    Hope this help.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this following setup, a textarea named with some data in it that
I have a setup like this: <div id=container> <div id=close>Close</div> </div> Then in my
Our VSS setup is like this: We have a set of unique folders with
I have a page that is setup like this public partial class _Default :
I have a simple ViewController that looks like this: @interface MyViewController : UIViewController<UIScrollViewDelegate> {
I have this code for a scrollview to showe 3 images: const CGFloat kScrollObjHeight
I have this setup where in my development copy I can commit changes on
On my portfolio page I have this setup: <div id=portfolio> <ul id=sites> <li> <h3><a
I have this membership site setup on my local machine using the ASP.NET membership
I have this test case def setUp(self): self.user = User.objects.create(username=tauri, password='gaul') def test_loginin_student_control_panel(self): c

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.