summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJeff Brown <jeffbrown@google.com>2011-04-12 22:39:53 -0700
committerJeff Brown <jeffbrown@google.com>2011-04-19 15:35:51 -0700
commit2352b978a3c94cd88f41d0d908f961333fdac1e9 (patch)
tree24f8f19e9b2895cc2c3489bf2dd7a09aaf5834db /include
parentf76dc56c33ba66138af70d72803cf55f881c3717 (diff)
downloadframeworks_base-2352b978a3c94cd88f41d0d908f961333fdac1e9.zip
frameworks_base-2352b978a3c94cd88f41d0d908f961333fdac1e9.tar.gz
frameworks_base-2352b978a3c94cd88f41d0d908f961333fdac1e9.tar.bz2
Initial checkin of spot presentation for touchpad gestures.
Added a new PointerIcon API (hidden for now) for loading pointer icons. Fixed a starvation problem in the native Looper's sendMessage implementation which caused new messages to be posted ahead of old messages sent with sendMessageDelayed. Redesigned the touch pad gestures to be defined in terms of more fluid finger / spot movements. The objective is to reinforce the natural mapping between fingers and spots which means there must not be any discontinuities in spot motion relative to the fingers. Removed the SpotController stub and folded its responsibilities into PointerController. Change-Id: I5126b1e69d95252fda7f2a684c9287e239a57163
Diffstat (limited to 'include')
-rw-r--r--include/ui/Input.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/ui/Input.h b/include/ui/Input.h
index 0dc29c8..9b92c73 100644
--- a/include/ui/Input.h
+++ b/include/ui/Input.h
@@ -620,6 +620,11 @@ private:
// Oldest sample to consider when calculating the velocity.
static const nsecs_t MAX_AGE = 200 * 1000000; // 200 ms
+ // When the total duration of the window of samples being averaged is less
+ // than the window size, the resulting velocity is scaled to reduce the impact
+ // of overestimation in short traces.
+ static const nsecs_t MIN_WINDOW = 100 * 1000000; // 100 ms
+
// The minimum duration between samples when estimating velocity.
static const nsecs_t MIN_DURATION = 10 * 1000000; // 10 ms