android Programming Glossary: e.gety
Android multi-touch support http://stackoverflow.com/questions/2679473/android-multi-touch-support 1 0 Finger currentLeftFinger new Finger e.getX firstIndex e.getY firstIndex Finger currentRightFinger new Finger e.getX secondIndex.. Finger currentRightFinger new Finger e.getX secondIndex e.getY secondIndex float yDifference Math.abs currentLeftFinger.getY..
Overlay images onto Camera preview SurfaceView http://stackoverflow.com/questions/3548666/overlay-images-onto-camera-preview-surfaceview e cr.mAngleX e.getX TRACKBALL_SCALE_FACTOR cr.mAngleY e.getY TRACKBALL_SCALE_FACTOR requestRender return true @Override public.. onTouchEvent MotionEvent e float x e.getX float y e.getY switch e.getAction case MotionEvent.ACTION_MOVE float dx..
Possibility of a Curved Gallery http://stackoverflow.com/questions/3732739/possibility-of-a-curved-gallery e if getAdapter null if pointToPosition int e.getX int e.getY getSelectedItemPosition return true else return super.onSingleTapUp..
Gesture in listview android http://stackoverflow.com/questions/3921138/gesture-in-listview-android lv getListView int pos lv.pointToPosition int e.getX int e.getY myOnItemClick pos return false @Override public boolean onFling..
android: MapView does not recognize clicks http://stackoverflow.com/questions/4513766/android-mapview-does-not-recognize-clicks p mapView.getProjection .fromPixels int e.getX int e.getY MyMapActivity this.startActivityForResult intent requestCode..
DoubleTap in android http://stackoverflow.com/questions/4804798/doubletap-in-android boolean onDoubleTap MotionEvent e float x e.getX float y e.getY Log.d Double Tap Tapped at x y return true share improve..
ScrollView inside Gallery, both scrolling independently http://stackoverflow.com/questions/5286115/scrollview-inside-gallery-both-scrolling-independently false mNeedToRebase true mInitialX e.getX mInitialY e.getY return false case MotionEvent.ACTION_MOVE if mIgnore float.. deltaX Math.abs e.getX mInitialX float deltaY Math.abs e.getY mInitialY mIgnore deltaX deltaY return mIgnore return false..
How to intercept touchscreen events in Android OpenGL ES? http://stackoverflow.com/questions/5453855/how-to-intercept-touchscreen-events-in-android-opengl-es boolean onTouchEvent MotionEvent e float x e.getX float y e.getY switch e.getAction case MotionEvent.ACTION_MOVE float dx x mPreviousX..
How do I modify TouchImageView with double tap to zoom in and out? http://stackoverflow.com/questions/7704086/how-do-i-modify-touchimageview-with-double-tap-to-zoom-in-and-out boolean onDoubleTap MotionEvent e float x e.getX float y e.getY LogUtil.i TAG Tapped at x y if isZoomed zoomOut else zoomIn..
Android - ListView slide left/right like Samsung contact ListView http://stackoverflow.com/questions/9321016/android-listview-slide-left-right-like-samsung-contact-listview case MotionEvent.ACTION_DOWN historicX e.getX historicY e.getY break case MotionEvent.ACTION_UP if e.getX historicX TRIGGER_DELTA..
Android multi-touch support http://stackoverflow.com/questions/2679473/android-multi-touch-support e.getX 0 e.getX 1 0 1 int secondIndex e.getX 0 e.getX 1 1 0 Finger currentLeftFinger new Finger e.getX firstIndex e.getY firstIndex Finger currentRightFinger new Finger e.getX secondIndex e.getY secondIndex float yDifference Math.abs currentLeftFinger.getY.. new Finger e.getX firstIndex e.getY firstIndex Finger currentRightFinger new Finger e.getX secondIndex e.getY secondIndex float yDifference Math.abs currentLeftFinger.getY currentRightFinger.getY if yDifference 80 Log.d GESTURE not..
Overlay images onto Camera preview SurfaceView http://stackoverflow.com/questions/3548666/overlay-images-onto-camera-preview-surfaceview public boolean onTrackballEvent MotionEvent e cr.mAngleX e.getX TRACKBALL_SCALE_FACTOR cr.mAngleY e.getY TRACKBALL_SCALE_FACTOR requestRender return true @Override public boolean onTouchEvent MotionEvent e float x e.getX float.. requestRender return true @Override public boolean onTouchEvent MotionEvent e float x e.getX float y e.getY switch e.getAction case MotionEvent.ACTION_MOVE float dx x mPreviousX float dy y mPreviousY cr.mAngleX dx TOUCH_SCALE_FACTOR..
Possibility of a Curved Gallery http://stackoverflow.com/questions/3732739/possibility-of-a-curved-gallery
Gesture in listview android http://stackoverflow.com/questions/3921138/gesture-in-listview-android public boolean onSingleTapUp MotionEvent e ListView lv getListView int pos lv.pointToPosition int e.getX int e.getY myOnItemClick pos return false @Override public boolean onFling MotionEvent e1 MotionEvent e2 float velocityX float velocityY..
android: MapView does not recognize clicks http://stackoverflow.com/questions/4513766/android-mapview-does-not-recognize-clicks MapView mapView if e.getAction MotionEvent.ACTION_UP GeoPoint p mapView.getProjection .fromPixels int e.getX int e.getY MyMapActivity this.startActivityForResult intent requestCode return false MyMapActivity methods @Override public void..
DoubleTap in android http://stackoverflow.com/questions/4804798/doubletap-in-android
ScrollView inside Gallery, both scrolling independently http://stackoverflow.com/questions/5286115/scrollview-inside-gallery-both-scrolling-independently e switch e.getAction case MotionEvent.ACTION_DOWN mIgnore false mNeedToRebase true mInitialX e.getX mInitialY e.getY return false case MotionEvent.ACTION_MOVE if mIgnore float deltaX Math.abs e.getX mInitialX float deltaY Math.abs e.getY.. return false case MotionEvent.ACTION_MOVE if mIgnore float deltaX Math.abs e.getX mInitialX float deltaY Math.abs e.getY mInitialY mIgnore deltaX deltaY return mIgnore return false default return super.onInterceptTouchEvent e share..
How to intercept touchscreen events in Android OpenGL ES? http://stackoverflow.com/questions/5453855/how-to-intercept-touchscreen-events-in-android-opengl-es e into your class extending GlsurfaceView. @Override public boolean onTouchEvent MotionEvent e float x e.getX float y e.getY switch e.getAction case MotionEvent.ACTION_MOVE float dx x mPreviousX float dy y mPreviousY mRenderer.mAngleX dx TOUCH_SCALE_FACTOR..
How do I modify TouchImageView with double tap to zoom in and out? http://stackoverflow.com/questions/7704086/how-do-i-modify-touchimageview-with-double-tap-to-zoom-in-and-out e return true event when double tap occurs @Override public boolean onDoubleTap MotionEvent e float x e.getX float y e.getY LogUtil.i TAG Tapped at x y if isZoomed zoomOut else zoomIn return true public boolean isZoomed return saveScale minScale..
Android - ListView slide left/right like Samsung contact ListView http://stackoverflow.com/questions/9321016/android-listview-slide-left-right-like-samsung-contact-listview public boolean onTouchEvent MotionEvent e switch e.getAction case MotionEvent.ACTION_DOWN historicX e.getX historicY e.getY break case MotionEvent.ACTION_UP if e.getX historicX TRIGGER_DELTA onSlideComplete Direction.LEFT return true else if..
|