summaryrefslogtreecommitdiff
path: root/core/java/android/view/MotionEvent.java
diff options
context:
space:
mode:
authorJeff Brown <jeffbrown@google.com>2011-03-03 02:09:54 -0800
committerJeff Brown <jeffbrown@google.com>2011-03-03 02:28:51 -0800
commitd41cff2d3a95963a7aa348e502c6d42bae367235 (patch)
treecd4a20f95dd1dfe6a2b9daeea128de658f39a987 /core/java/android/view/MotionEvent.java
parent9225b00a3dc45bdbcfb6adafa4dbbc0cbe9be864 (diff)
Fix off by one errors in touch motion ranges.
Report inclusive minimum and maximum ranges for all axes including X and Y. Set mouse pointer bounds to 0..width-1, 0..height-1. Rotate touch and mouse positions more carefully, paying attention to the maximum bounds when calculating the complement of an axis. Simplified the InputReader somewhat and removed support for a couple of poorly defined input device configuration parameters. We now assume that the touch device provides useful absolute axis ranges for the X and Y axes since the alternative does not actually make sense. Bug: 3413541 Change-Id: I682ce3729e4473de7f1bcf8addb49a3f4484126f
Diffstat (limited to 'core/java/android/view/MotionEvent.java')
-rw-r--r--core/java/android/view/MotionEvent.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/java/android/view/MotionEvent.java b/core/java/android/view/MotionEvent.java
index 076f71298490..f70f1fb92a4b 100644
--- a/core/java/android/view/MotionEvent.java
+++ b/core/java/android/view/MotionEvent.java
@@ -2071,6 +2071,8 @@ public final class MotionEvent extends InputEvent implements Parcelable {
* MotionEvent. For touch events, clients can use this to determine if the
* user's finger was touching the edge of the display.
*
+ * This property is only set for {@link #ACTION_DOWN} events.
+ *
* @see #EDGE_LEFT
* @see #EDGE_TOP
* @see #EDGE_RIGHT