Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

onSingleTapConfirmed gesture only being called when debugger is attached #561

Open
akashpopat-honest opened this issue Nov 11, 2021 · 1 comment

Comments

@akashpopat-honest
Copy link

Expected behaviour

onSingleTapConfirmed should get a callback and show a Log/Toast when on called according to the logic but it doesn't.

Actual behaviour

It doesn't get the callback but it does get the callback if the debugger is attached to the device.

Steps to reproduce

Tested on Emulator with the following code -
`

gestureDetector = new GestureDetector(this, new GestureDetector.SimpleOnGestureListener() {
        @Override
        public boolean onSingleTapConfirmed(MotionEvent e) {
            if (mapIv.isReady()) {
                PointF sCoord = mapIv.viewToSourceCoord(e.getX(), e.getY());
                Toast.makeText(HomeActivity.this, "touched x:" + sCoord.x + ", y:" + sCoord.y, Toast.LENGTH_LONG).show();
            }
            return true;
        }
    });
    mapIv.setOnTouchListener(new View.OnTouchListener() {
        @Override
        public boolean onTouch(View view, MotionEvent motionEvent) {
            return gestureDetector.onTouchEvent(motionEvent);
        }
    });

`

Affected devices

Tested on Pixel 3a emulator with android 10

@bharathgrandhe-utu
Copy link

Happening the same for me too. Any update on this??

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants