@Override public boolean onSingleTapConfirmed(final MotionEvent arg0) { if (_mode == MODE_DYNAMIC) { // we owe an ACTION_UP, so we fake an arg0.setAction(ACTION_FAKE); // action which will be converted to an ACTION_UP later. _context.dispatchTouchEvent(arg0); } return false; }
@Override public boolean dispatchTouchEvent(MotionEvent e) { int scrollY = webview.getScrollY(); if (scrollY == 0 || (float) scrollY >= webview.getContentHeight() * getScale(webview) - webview.getHeight()) { setDisplayZoomControls(true); } else { setDisplayZoomControls(false); } super.dispatchTouchEvent(e); // getActionMasked since api-8 switch (e.getAction() & MotionEvent.ACTION_MASK) { case MotionEvent.ACTION_CANCEL: case MotionEvent.ACTION_UP: scale = getScale(webview); break; } return mGestureDetector.onTouchEvent(e); }
public boolean dispatchTouchEvent(MotionEvent event) { super.dispatchTouchEvent(event); return m.gestureDetector.onTouchEvent(event); }
@Override public boolean onTouchEvent(MotionEvent event) { return activity.dispatchTouchEvent(event); }