summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJeff Brown <jeffbrown@google.com>2010-06-29 16:52:21 -0700
committerJeff Brown <jeffbrown@google.com>2010-06-29 16:52:21 -0700
commit4036f7f2b44351a8d964b5cdfdf7b787795cf041 (patch)
treebf5d7265e651a7aae3551ba28ed0dd190bfee8e1 /include
parent0c9c6f85b08667ab4a4c9265674bd542e7b0a4a5 (diff)
downloadframeworks_native-4036f7f2b44351a8d964b5cdfdf7b787795cf041.zip
frameworks_native-4036f7f2b44351a8d964b5cdfdf7b787795cf041.tar.gz
frameworks_native-4036f7f2b44351a8d964b5cdfdf7b787795cf041.tar.bz2
Fix native input dispatch in the emulator.
Set a default orientation of ROTATION_0. Added some more careful checks based on whether we have valid absolute axis information from the driver. Reset key repeating during configuration changes since the keyboard device may have been removed. Change-Id: I685960828acffcb17595fc5683309e8064a76714
Diffstat (limited to 'include')
-rw-r--r--include/ui/InputReader.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/ui/InputReader.h b/include/ui/InputReader.h
index 2093560..8f6777d 100644
--- a/include/ui/InputReader.h
+++ b/include/ui/InputReader.h
@@ -53,6 +53,8 @@ extern int32_t rotateKeyCode(int32_t keyCode, int32_t orientation);
*/
struct InputDevice {
struct AbsoluteAxisInfo {
+ bool valid; // set to true if axis parameters are known, false otherwise
+
int32_t minValue; // minimum value
int32_t maxValue; // maximum value
int32_t range; // range of values, equal to maxValue - minValue
@@ -272,9 +274,16 @@ struct InputDevice {
} jumpyTouchFilter;
struct Precalculated {
+ int32_t xOrigin;
float xScale;
+
+ int32_t yOrigin;
float yScale;
+
+ int32_t pressureOrigin;
float pressureScale;
+
+ int32_t sizeOrigin;
float sizeScale;
} precalculated;