1e08fe90df18930691b0c2ec22e5db25d7fcb4cf |
|
16-Nov-2011 |
Jeff Brown <jeffbrown@google.com> |
Eliminate hw.keyboards system properties. Stop using system properties to publish information about the key character map path. Instead, we can retrieve it on demand by asking the window manager. It was possible to exhaust the supply of system properties when repeatedly adding and removing input devices. Bug: 5532806 Change-Id: Idd361a24ad7db2edc185c8546db7fb05f9c28669
/frameworks/base/services/input/tests/InputReader_test.cpp
|
9ee285afe740ff13d176c9d8430979dfd9575a23 |
|
31-Aug-2011 |
Jeff Brown <jeffbrown@google.com> |
Support composite touch / joystick devices better. This change enables the joystick input mapper to handle any axes that are not claimed by the touch input mapper, which makes auxiliary controls such as wheels / knobs accessible. Change-Id: I01ee7f342ac91acfcb4ccb6676fd52b3d5bf31a0
/frameworks/base/services/input/tests/InputReader_test.cpp
|
ea6892e02e10a57673a42f0922ad28694595dcaa |
|
24-Aug-2011 |
Jeff Brown <jeffbrown@google.com> |
Support BTN_TOOL_*TAP as synonyms for BTN_TOOL_FINGER. Bug: 5205301 Some drivers report one finger as BTN_TOOL_FINGER, two as BTN_TOOL_DOUBLETAP, three as BTN_TOOL_TRIPLETAP and four as BTN_TOOL_QUADTAP. Since we care about the tool type, we need to handle _DOUBLE/_TRIPLE/_QUAD tap in the same way we handle _FINGER. Change-Id: I8eb83d2a2bada9ac32d07619c7eea84e924316b8
/frameworks/base/services/input/tests/InputReader_test.cpp
|
65fd251c3913fc921468a3dad190810db19eb9df |
|
18-Aug-2011 |
Jeff Brown <jeffbrown@google.com> |
Input system bug fixes, particularly for stylus. Bug: 5049148 Finished stylus support, including support for indirect stylus and mouse tools. Added TILT axis. When stylus tilt X/Y is available, it is transformed into an orientation and tilt inclination which is a more convenient representation and a simpler extension to the exiting API. Touch devices now only report touch data using a single input source. Previously touch devices in pointer mode would report both absolute touch pad data and cooked pointer gestures. Now we just pick one. The touch device switches modes as needed when the focused application enables/disables pointer gestures. This change greatly simplifies the code and reduces the load on the input dispatcher. Fixed an incorrect assumption that the value of ABS_(MT_)DISTANCE would be zero whenever the stylus was in direct contact. It appears that the correct way to determine whether the stylus is in direct contact (rather than hovering) is by checking for a non-zero reported pressure. Added code to read the initial state of tool buttons and axis values when the input devices are initialized or reset. This fixes problems where the input mapper state might have the wrong initial state. Moved responsibility for cancelling pending inputs (keys down, touches, etc.) to the InputDispatcher by sending it a device reset notification. This frees the InputReader from having to synthesize events during reset, which was cumbersome and somewhat brittle to begin with. Consolidated more of the common accumulator logic from SingleTouchInputMapper and MultiTouchInputMapper into TouchInputMapper. Improved the PointerLocation output. Change-Id: I595d3647f7fd7cb1e3eff8b3c76b85043b5fe2f0
/frameworks/base/services/input/tests/InputReader_test.cpp
|
a1f89ceec076392da409e9f389b33e62e1d92da6 |
|
11-Aug-2011 |
Jeff Brown <jeffbrown@google.com> |
Improve touch device configuration. Bug: 5064702 This change improves compatibility with standard touch device drivers. All existing touch device IDC files will need to be updated because the input system now assumes that the touch device drivers implement the multitouch input protocol correctly and use the appropriate axes. Change-Id: I93aad0e011efea74fbc7fa3da31f7967aff8136c
/frameworks/base/services/input/tests/InputReader_test.cpp
|
89ef0720ee8e0ac6ae1758faa917e4d6c9606fb4 |
|
11-Aug-2011 |
Jeff Brown <jeffbrown@google.com> |
Add input system to Watchdog. Bug: 5094994 Change-Id: I153866958efc64ac19bda8b997c1c9f6ad425ec4
/frameworks/base/services/input/tests/InputReader_test.cpp
|
be1aa8250cee7819c49741e819e81659d1d03823 |
|
28-Jul-2011 |
Jeff Brown <jeffbrown@google.com> |
Refactor input reader to add stylus support. Bug: 5064702 Introduced the concept of an InputListener to further decouple the InputReader from the InputDispatcher. The InputListener exposes just the minimum interface that the InputReader needs to communicate with the outside world. The InputReader passes arguments to the InputListener by reference, which makes it easy to queue them up. Consolidated all of the InputReader locks into one simple global Mutex. The reason this wasn't done before was due to potential re-entrance in outbound calls to the InputDispatcher. To fix this, the InputReader now queues up all of the events it wants to send using a QueuedInputListener, then flushes them outside of the critical section after all of the event processing is finished. Removing all of the InputMapper locks greatly simplifies the implementation. Added tests for new stylus features such as buttons, tool types, and hovering. Added some helpers to BitSet32 to handle common code patterns like finding the first marked bit and clearing it. Fixed a bug in VelocityTracker where the wrong pointer trace could get cleared when handling ACTION_POINTER_DOWN. Oops. Changed PointerCoords so it no longer stores useless zero axis values. Removed editAxisValue because it is not very useful when all zero value axes are absent and therefore cannot be edited in place. Added dispatch of stylus hover events. Added support for distance and tool types. Change-Id: I4cf14d134fcb1db7d10be5f2af7b37deef8f8468
/frameworks/base/services/input/tests/InputReader_test.cpp
|
bc68a59c024bdb745dac8e2ec7408a9f30595f1a |
|
25-Jul-2011 |
Jeff Brown <jeffbrown@google.com> |
Report the external display size to the input reader. The input reader needs this information so that it knows how to interpolate touches on an external touch screen. Changed Display so that it asks the WindowManager what the real display size is (as opposed to the raw display size). This means it now takes into the forced display size set by adb shell am display-size. Replaced all calls to getRealWidth() / getRealHeight() / getRealMetrics() in the WindowManager and replaced them with direct usages of the mCurDisplayWidth / mCurDisplayHeight so that the WM doesn't end up making a reentrant Binder call into itself. Fixed the table status bar HeightReceiver so that it updates the height on all configuration changes since it is possible that the display size changed independently of an external HDMI display being plugged / unplugged. Improved the Display class documentation to make the distinctions betweeen the various sizes clearer. Change-Id: I3f75de559d3ebffed532ab46c4ae52c5e7f1da2b
/frameworks/base/services/input/tests/InputReader_test.cpp
|
49754db5a304d995c1cc108ff6f19e4ba4265572 |
|
02-Jul-2011 |
Jeff Brown <jeffbrown@google.com> |
Handle stylus buttons and tool types. Added TOOL_TYPE_ERASER. Refactored the InputReader to share more code between the various input mappers that handle button states and to simplify the accumulator implementations by having each one only handle a single type of input. Removed the concept of direct/indirect tool types from the API. If we add it back, it should be done in a manner that is orthogonal to the tool type itself, perhaps as a flags field on the pointer. The device source may well provide sufficient information anyhow. Change-Id: I811c22d95e8304269b6ee4f6d11a6b04f3cfc1b2
/frameworks/base/services/input/tests/InputReader_test.cpp
|
9302c8796fc4dcda08d4bd1e11733848fd4fafaf |
|
14-Jul-2011 |
Jeff Brown <jeffbrown@google.com> |
Refactor input dispatcher use of window/app handles. This change moves the cached window and application input state into the handle objects themselves. It simplifies the dispatcher somewhat because it no longer needs to fix up references to transient InputWindow objects each time the window list is updated. This change will also make it easier to optimize setInputWindows to avoid doing a lot of redundant data copying. In principle, only the modified fields need to be updated. However, for now we continue to update all fields in unison as before. It turns out that the input dispatcher was inappropriately retaining pointers to InputWindow objects within the mWindows InputWindow vector. This vector is copy-on-write so it is possible and the item pointers to change if an editing operation is performed on the vector when it does not exclusively own the underlying SharedBuffer. This bug was uncovered by a previous change that replaced calls to clear() and appendVector() with a simple use of operator= which caused the buffer to be shared. Consequently after editItemAt was called (which it shouldn't have, actually) the buffer was copied and the cached InputWindow pointers became invalid. Oops. This change fixes the problem. Change-Id: I0a259339a6015fcf9113dc4081a6875e047fd425
/frameworks/base/services/input/tests/InputReader_test.cpp
|
a4d1bc517207d7ca8d56f0004cd04f0f1dd4567d |
|
02-Jul-2011 |
Jeff Brown <jeffbrown@google.com> |
Drop obsolete touch screen hacks. Change-Id: I47354c37ee2cc2b36340eb709bb5043b3ba78ed9
/frameworks/base/services/input/tests/InputReader_test.cpp
|
6894a2947eb1f9d499fd7f1a1ec4e7098e07d25d |
|
02-Jul-2011 |
Jeff Brown <jeffbrown@google.com> |
Workaround apps that make assumptions about pointer ids. Modified the touch input mapper to assign pointer ids sequentially starting from 0 instead of using the tracking id or slot index supplied by the driver. Applications should not depend on this ordering but some do. (sigh) Bug: 4980884 Change-Id: I0dfeb3ac27c57a7102a13c960c760e2a02eb7669
/frameworks/base/services/input/tests/InputReader_test.cpp
|
2717eff2ac04bed60e5fd577bcb8ec1ea7c2ccde |
|
01-Jul-2011 |
Jeff Brown <jeffbrown@google.com> |
Query input device for initial slot index. This fixes a problem where touches can get stuck because the driver and the framework have different ideas of what the initial slot index is. The framework assumed it was slot 0 but it could in principle be any slot, such as slot 1. When that happened, the framework would start tracking the first touch as slot 0, but it might never receive an "up" for that slot. Change-Id: Idaffc4534b275d66b9d4360987b28dc2d0f63218
/frameworks/base/services/input/tests/InputReader_test.cpp
|
474dcb5c3ddff737c4ac9fc44a1f7be569605e5f |
|
15-Jun-2011 |
Jeff Brown <jeffbrown@google.com> |
Add support for disabling pointer gestures. Made it possible for individual windows to disable pointer gestures while the window has focus using a private API. Cleaned up the InputReader configuration code to enable in-place reconfiguration of input devices without having to reopen them all. This change makes changing the pointer speed somewhat nicer since the pointer doesn't jump back to the origin after each change. Change-Id: I9727419c2f4cb39e16acb4b15fd7fd84526b1239
/frameworks/base/services/input/tests/InputReader_test.cpp
|
93fa9b30b91f75ee161d0791ff17f98d1a603812 |
|
15-Jun-2011 |
Jeff Brown <jeffbrown@google.com> |
EventHub code cleanup. Use epoll_wait() instead of poll(). Dropped all support for non-Linux platforms. Added a wake-up protocol so that the InputReader can wake up the event loop immediately as needed. Change-Id: Ibf84337bcceb3c2df068c5c637de42a319786d66
/frameworks/base/services/input/tests/InputReader_test.cpp
|
b3a2d1330716812784aee91b6d6275764b5e4210 |
|
13-Jun-2011 |
Jeff Brown <jeffbrown@google.com> |
Take advantage of updated linux/input.h kernel headers. Change-Id: I72d2ef82de5c504d46b0cdb57aa43bbd0d769174
/frameworks/base/services/input/tests/InputReader_test.cpp
|
cb0c55ed37495dfd5b04a80c9e024f91ba926109 |
|
08-Jun-2011 |
Jeff Brown <jeffbrown@android.com> |
am e046555b: am fd324486: am 5cb05eea: Merge "Fix build." into honeycomb-mr2 * commit 'e046555b4d92179327d12d888be967fff5c027ca': Fix build.
|
9181a5f40cf5ac7d413d5bc3bd6c15cc6d13705f |
|
07-Jun-2011 |
Jeff Brown <jeffbrown@android.com> |
Fix build. Change-Id: I9ea07637058e2aa74d20d881bc21fea305cc869e
/frameworks/base/services/input/tests/InputReader_test.cpp
|
7218d830e27d81141588cd6e37f206d141a18f62 |
|
04-Jun-2011 |
Jeff Brown <jeffbrown@google.com> |
resolved conflicts for merge of ca2b552d to master Change-Id: I2f3693a59042ac5aa2d7bcdc3a504c78dc99a18b
|
f3b57def9345d6d3cac3604d6a970f6d48f345ec |
|
03-Jun-2011 |
Dianne Hackborn <hackbod@google.com> |
resolved conflicts for merge of 7e193916 to master Change-Id: If06892419319c3a2d4ab6b03dd3ceb99b83803b5
|
1a84fd1fb7a51f3fe4f8865e1cdd09f3490f696c |
|
02-Jun-2011 |
Jeff Brown <jeffbrown@android.com> |
Add a preference panel for mouse speed. Bug: 4124987 Change-Id: I3ce175d268a1d043cf5878481261b1049a15a149
/frameworks/base/services/input/tests/InputReader_test.cpp
|
b530abcff5ae8e5ebb75ec6aa42b7c7c190e98a5 |
|
01-Jun-2011 |
Jeff Brown <jeffbrown@android.com> |
am 3f5b95b0: am a4e74744: am fa574c0e: Merge "Touch pad UX improvements." into honeycomb-mr2 * commit '3f5b95b05efcf7ab2e8f193649b841dc1786f2ef': Touch pad UX improvements.
|
214eaf48878bba00cbd5831871bcbd82632b6e34 |
|
27-May-2011 |
Jeff Brown <jeffbrown@android.com> |
Use ViewConfiguration to seed input system configuration. Fix bug where the pointer presentation would be updated on any input reader timeout rather than only when a pointer gesture is in progress. Bug: 4124987 Change-Id: Ie9bba4a0b3228d55e45e65fa2ede5cd6ba887a08
/frameworks/base/services/input/tests/InputReader_test.cpp
|
538881e18323a0c983bd8809f8c3b1cdeeeab8a6 |
|
26-May-2011 |
Jeff Brown <jeffbrown@android.com> |
Touch pad UX improvements. Fade the pointer spot when swiping or performing a freeform gesture. Support configuring the gesture mode in the device IDC file. Added workaround for devices that report individual finger movements one at a time instead of all at once. Bug: 4124987 Change-Id: I44628b00382ad59306e4ec5c4717d69cc6fbebb8
/frameworks/base/services/input/tests/InputReader_test.cpp
|
86ea1f5f521981d075aef56f11693e4f3bc32fdb |
|
13-Apr-2011 |
Jeff Brown <jeffbrown@google.com> |
Initial checkin of spot presentation for touchpad gestures. (DO NOT MERGE) 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: Ib647dbd7a57a7f30dd9c6e2c260df51d7bbdd18e
/frameworks/base/services/input/tests/InputReader_test.cpp
|
a6dbfdd3a858aac52cc87f80f91e8eef7d613605 |
|
11-Apr-2011 |
Jeff Brown <jeffbrown@google.com> |
Add a sprite controller. (DO NOT MERGE) Refactored PointerController to extract the surface management code to a new component called a SpriteController so that it can be used to move finger tracking spots around the screen as well. The SpriteController is designed to fully decouple the client from any latency introduced by surface transactions and drawing. All sprite updates are performed asynchronously on the Looper using a copy of the sprite state. Added a stub SpotController implementation for touch pad UX. It will be implemented in a subsequent patch. Fixed a little bug in pointer orientation changes when entering DISPLAY_ORIENTATION_90 the x offset was clobbered. Change-Id: I6d59d80df9af61e93af50290e7776337d10c9d5a
/frameworks/base/services/input/tests/InputReader_test.cpp
|
dbf8d27f4c32e20e132e90ad713c6ebaf71d7756 |
|
19-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Optimize EventHub to process events in big chunks. (DO NOT MERGE) When 10 fingers are down, reduces the CPU time spent by the InputReader thread from ~30% to ~5% on Stingray. Change-Id: I42ee5c67b8521af715cbab43e763a4af4eb1f914
/frameworks/base/services/input/tests/InputReader_test.cpp
|
80fd47ce75253dcdc2cfa85d7a3f42634b923a47 |
|
24-May-2011 |
Jeff Brown <jeffbrown@google.com> |
Input device protocol enhancements. Added support for Linux multitouch protocol B (slots). Added support for using the device's input properties as a hint to determine the intended usage of a touch device. Added support for the ABS_MT_DISTANCE axis. Fixed a bug reporting the presence of the orientation axis. Change-Id: Icf7b5a5a0f1a9cdf6ad2b35be8ea0c1a35815d48
/frameworks/base/services/input/tests/InputReader_test.cpp
|
68d6075b4ad2205c10064c78cde552e3210cca91 |
|
17-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Refactor how timeouts are calculated. (DO NOT MERGE) Added a timeout mechanism to EventHub and InputReader so that InputMappers can request timeouts to perform delayed processing of input when needed. Change-Id: I89c1171c9326c6e413042e3ee13aa9f7f1fc0454
/frameworks/base/services/input/tests/InputReader_test.cpp
|
96ad3979f328a1aa098917ca1c35575e85345526 |
|
10-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Use touch pad gestures to manipulate the pointer. (DO NOT MERGE) 1. Single finger tap performs a click. 2. Single finger movement moves the pointer (hovers). 3. Button press plus movement performs click or drag. While dragging, the pointer follows the finger that is moving fastest. This is important if there are additional fingers down on the touch pad for the purpose of applying force to an integrated button underneath. 4. Two fingers near each other moving in the same direction are coalesced as a swipe gesture under the pointer. 5. Two or more fingers moving in arbitrary directions are transformed into touches in the vicinity of the pointer. This makes scale/zoom and rotate gestures possible. Added a native VelocityTracker implementation to enable intelligent switching of the active pointer during drags. Change-Id: I7b7ddacc724fb1306e1590dbaebb740d3130d7cd
/frameworks/base/services/input/tests/InputReader_test.cpp
|
fe9f8ab03a63b1037f07dd85799fbea80ec6adaa |
|
07-May-2011 |
Jeff Brown <jeffbrown@google.com> |
Add initial API for stylus and mouse buttons. Added the concept of pointer properties in a MotionEvent. This is currently used to track the pointer tool type to enable applications to distinguish finger touches from a stylus. Button states are also reported to application as part of touch events. There are no new actions for detecting changes in button states. The application should instead query the button state from the MotionEvent and take appropriate action as needed. A good time to check the button state is on ACTION_DOWN. As a side-effect, applications that do not support multiple buttons will treat primary, secondary and tertiary buttons identically for all touch events. The back button on the mouse is mapped to KEYCODE_BACK and the forward button is mapped to KEYCODE_FORWARD. Added basic plumbing for the secondary mouse button to invoke the context menu, particularly in lists. Added clamp and split methods on MotionEvent to take care of common filtering operations so we don't have them scattered in multiple places across the framework. Bug: 4260011 Change-Id: Ie992b4d4e00c8f2e76b961da0a902145b27f6d83
/frameworks/base/services/input/tests/InputReader_test.cpp
|
2352b978a3c94cd88f41d0d908f961333fdac1e9 |
|
13-Apr-2011 |
Jeff Brown <jeffbrown@google.com> |
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
/frameworks/base/services/input/tests/InputReader_test.cpp
|
5541de9ea3513a12d1ac2ad07e7e04a3aa7741a0 |
|
11-Apr-2011 |
Jeff Brown <jeffbrown@google.com> |
Add a sprite controller. Refactored PointerController to extract the surface management code to a new component called a SpriteController so that it can be used to move finger tracking spots around the screen as well. The SpriteController is designed to fully decouple the client from any latency introduced by surface transactions and drawing. All sprite updates are performed asynchronously on the Looper using a copy of the sprite state. Added a stub SpotController implementation for touch pad UX. It will be implemented in a subsequent patch. Fixed a little bug in pointer orientation changes when entering DISPLAY_ORIENTATION_90 the x offset was clobbered. Change-Id: Ib25d162d577c9b354cb74d5d761c3c9f9f438d42
/frameworks/base/services/input/tests/InputReader_test.cpp
|
0029c66203ab9ded4342976bf7a17bb63af8c44a |
|
30-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Add input filter mechanism for accessibility. This patch adds a mechanism for capturing, filtering, transforming and injecting input events at a very low level before the input dispatcher attempts to deliver them to applications. At this time, the mechanism is only intended to be used by the accessibility system to implement built-in system-level accessibility affordances. The accessibility input filter is currently just a stub. It logs the input events receives and reinjects them unchanged, except that it transforms KEYCODE_Q into KEYCODE_Z. Currently, the accessibility input filter is installed whenever accessibility is enabled. We'll probably want to change that so it only enables the input filter when a screen reader is installed and we want touch exploration. Change-Id: I35764fdf75522b69d09ebd78c9766eb7593c1afe
/frameworks/base/services/input/tests/InputReader_test.cpp
|
df66797771550d243500943e1b9a177667f77f7a |
|
19-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Merge "Optimize EventHub to process events in big chunks."
|
b7198743ab3976b30d4655c1e065ca33e372b6af |
|
19-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Optimize EventHub to process events in big chunks. When 10 fingers are down, reduces the CPU time spent by the InputReader thread from ~30% to ~5% on Stingray. Change-Id: Icdf7c91cd5d9039ac3beb38ba9021a05e7fabc80
/frameworks/base/services/input/tests/InputReader_test.cpp
|
6ed6f6d82d7b9f8d82f3ab3a9f718a0e59ffa476 |
|
18-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Merge "Refactor how timeouts are calculated."
|
2120617f2fb10035022d1a3e76836a278a0e6a18 |
|
18-Mar-2011 |
James Dong <jdong@google.com> |
am 14438b81: am 970bad67: am be368de7: Merge "Fix missing AOSP copyright headers for more files" into honeycomb-mr1 * commit '14438b81a1fe4d7ebdf8977f3d80a1dd1867c5ad': Fix missing AOSP copyright headers for more files
|
aa3855d5836d2a2d83baafdf6e40caf90d3dad1c |
|
17-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Refactor how timeouts are calculated. Added a timeout mechanism to EventHub and InputReader so that InputMappers can request timeouts to perform delayed processing of input when needed. Change-Id: Iec2045baaf4e67690b15eef3c09a58d5cac76897
/frameworks/base/services/input/tests/InputReader_test.cpp
|
199d1c131d29b5356f71fbd7826a592c1dd8575f |
|
17-Mar-2011 |
James Dong <jdong@google.com> |
Fix missing AOSP copyright headers for more files o Update the copyright date on InputDispatcher_test.cpp and InputReader_test.cpp because these two files were moved from other places to the current location, and were actually created in 2010. bug - 4119349 Change-Id: Ic93b81ddafb58e9e72a2e9e02ca3d9f173d6dca7
/frameworks/base/services/input/tests/InputReader_test.cpp
|
ace13b17866dc9136aeecf6dfaf7077f37434469 |
|
10-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Use touch pad gestures to manipulate the pointer. 1. Single finger tap performs a click. 2. Single finger movement moves the pointer (hovers). 3. Button press plus movement performs click or drag. While dragging, the pointer follows the finger that is moving fastest. This is important if there are additional fingers down on the touch pad for the purpose of applying force to an integrated button underneath. 4. Two fingers near each other moving in the same direction are coalesced as a swipe gesture under the pointer. 5. Two or more fingers moving in arbitrary directions are transformed into touches in the vicinity of the pointer. This makes scale/zoom and rotate gestures possible. Added a native VelocityTracker implementation to enable intelligent switching of the active pointer during drags. Change-Id: I5ada57e7f2bdb9b0a791843eb354a8c706b365dc
/frameworks/base/services/input/tests/InputReader_test.cpp
|
efd3266b719eed5f1b217021c0a9e76e4b274b06 |
|
09-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Input improvements and bug fixes. Associate each motion axis with the source from which it comes. It is possible for multiple sources of the same device to define the same axis. This fixes new API that was introduced in MR1. (Bug: 4066146) Fixed a bug that might cause a segfault when using a trackball. Only fade out the mouse pointer when touching the touch screen, ignore other touch pads. Changed the plural "sources" to "source" in several places in the InputReader where we intend to refer to a particular source rather than to a combination of sources. Improved the batching code to support batching events from different sources of the same device in parallel. (Bug: 3391564) Change-Id: I0189e18e464338f126f7bf94370b928e1b1695f2
/frameworks/base/services/input/tests/InputReader_test.cpp
|
9626b14a283ef82d16636cf5fb5ba8bb4d30381e |
|
03-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Fix off by one errors in touch motion ranges. (DO NOT MERGE) 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: I121d28a125c4f9618cb283dc460d33ff1a907023
/frameworks/base/services/input/tests/InputReader_test.cpp
|
8529745b27877d98a0c76692295a3fcac238b1e6 |
|
04-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Joystick tweaks. (DO NOT MERGE) Ensure that the joystick can always reach -1.0, 0.0 and 1.0 positions even when noise filtering is applied. (Bug: 3514510) Add support for a few more standard axes. Add additional mapping modes for axes. Some axes are inverted from standard interpretation or are actually intended to be split into two distict axes such as left/right trigger controls or accelerator/brake. Add key layout file for a G25 racing wheel and XBox 360 controller to tweak behavior. They work fine without them but the axis mappings are not ideal. Change-Id: I0fddd90309af4dc14d35f34fe99ed6e521c0b7c7
/frameworks/base/services/input/tests/InputReader_test.cpp
|
56194ebec6212e229f4ccdaa4b187166d20013ef |
|
03-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Wake screen from external HID peripherals. Added some plumbing to enable the policy to intercept motion events when the screen is off to handle wakeup if needed. Added a basic concept of an external device to limit the scope of the wakeup policy to external devices only. The wakeup policy for internal devices should be based on explicit rules such as policy flags in key layout files. Moved isTouchEvent to native. Ensure the dispatcher sends the right event type to userActivity for non-touch pointer events like HOVER_MOVE and SCROLL. Bug: 3193114 Change-Id: I15dbd48a16810dfaf226ff7ad117d46908ca4f86
/frameworks/base/services/input/tests/InputReader_test.cpp
|
05dc66ada6b61a6bdf806ffaa62617ac5394695d |
|
02-Mar-2011 |
Jeff Brown <jeffbrown@google.com> |
Fade out the mouse pointer after inactivity or other events. Fades out the mouse pointer: - after 15 seconds of inactivity normally - after 3 seconds of inactivity in lights out mode - after a non-modifier key down - after a touch down Extended the native Looper to support enqueuing time delayed messages. This is used by the PointerController to control pointer fade timing. Change-Id: I87792fea7dbe2d9376c78cf354fe3189a484d9da
/frameworks/base/services/input/tests/InputReader_test.cpp
|
cc0c159e9b3dd4e0f48da0ce3e33d2c68a651413 |
|
19-Feb-2011 |
Jeff Brown <jeffbrown@google.com> |
Add new hover move action and scroll wheel plumbing. Added support for tracking the mouse position even when the mouse button is not pressed. To avoid confusing existing applications, mouse movements are reported using the new ACTION_HOVER_MOVE action when the mouse button is not pressed. Added some more plumbing for the scroll wheel axes. The values are reported to Views but they are not yet handled by the framework. Change-Id: I1706be850d25cf34e5adf880bbed5cc3265cf4b1
/frameworks/base/services/input/tests/InputReader_test.cpp
|
6f2fba428ca5e77a26d991ad728e346cc47609ee |
|
19-Feb-2011 |
Jeff Brown <jeffbrown@google.com> |
Add new axes for joysticks and mouse wheels. Added API on InputDevice to query the set of axes available. Added API on KeyEvent and MotionEvent to convert keycodes and axes to symbolic name strings for diagnostic purposes. Added API on KeyEvent to query if a given key code is a gamepad button. Added a new "axis" element to key layout files to specify the mapping between raw absolute axis values and motion axis ids. Expanded the axis bitfield to 64bits to allow for future growth. Modified the Makefile for keyboard prebuilts to run the keymap validation tool during the build. Added layouts for two game controllers. Added default actions for game pad button keys. Added more tests. Fixed a bunch of bugs. Change-Id: I73f9166c3b3c5bcf4970845b58088ad467525525
/frameworks/base/services/input/tests/InputReader_test.cpp
|
ebbd5d14ad3b1e762d9fcfa026e19413cc857e05 |
|
17-Feb-2011 |
Jeff Brown <jeffbrown@google.com> |
Fix a regression with MotionEvent parceling. Also added some more unit tests. Change-Id: I413654294d1a998eec056884e6df5eaa50f3daf4
/frameworks/base/services/input/tests/InputReader_test.cpp
|
91c69ab01539f7ba28708f41ec1835cc2920d0a0 |
|
15-Feb-2011 |
Jeff Brown <jeffbrown@google.com> |
Add support for arbitrary axes in MotionEvents. This change makes it possible to extend the set of axes that are reported in MotionEvents by defining new axis constants. The MotionEvent object is now backed by its C++ counterpart to avoid having to maintain multiple representations of the same data. Change-Id: Ibe93c90d4b390d43c176cce48d558d20869ee608
/frameworks/base/services/input/tests/InputReader_test.cpp
|
71c86ada9f00334b2967d24d4182dc324cd97605 |
|
08-Feb-2011 |
Jeff Brown <jeffbrown@google.com> |
Fix read from uninitialized memory. Change-Id: I75ce29d5971b386ff9dd52824a8953ce69a3ec15
/frameworks/base/services/input/tests/InputReader_test.cpp
|
58a2da843f2f22f406df8df1f011738eb8b7fcb1 |
|
26-Jan-2011 |
Jeff Brown <jeffbrown@google.com> |
Fix crashes caused by some input devices. The touch screen sometimes reports more than 10 pointers even though that's all we asked for. When this happens, we start dropping events with more than 10 pointers. This confuses applications and causes them to crash. Raised the limit to 16 pointers. Bug: 3331247 The default behavior was to identify all touch devices as touch screens. External devices that are plugged in are more likely to be touch pads not attached to a screen. Changed the default to be a touch pad and renamed some internal constants to avoid confusion. A certain mouse happens to also behave like a touch pad. That caused problems because we would see multiple concurrent traces of motion events coming from the same input device so we would batch them up. Added code to ensure that we don't batch events unless they come from the same *source* in addition to coming from the same *device*. Due to batching or misbehaving drivers, it's possible for the set of pointer ids to be different from what we expect when it comes time to split motion events across windows. As a result, we can generate motion events with 0 pointers. When we try to deliver those events, we cause an error in the InputTransport so we tear down the InputChannel and kill the application. Added code to check out assumption about pointer ids and drop the event gracefully instead. Patched up the tests to take into account the change in default behavior for identifying touch screens and touch pads. Change-Id: Ic364bd4cb4cc6335d4a1213a26d6bdadc7e33505
/frameworks/base/services/input/tests/InputReader_test.cpp
|
89de57a8d252a25ef2412a11a66089a9ff6ffe29 |
|
20-Jan-2011 |
Jeff Brown <jeffbrown@google.com> |
Fix getSwitchState. InputReader::getSwitchState always returns AKEY_STATE_UNKNOWN because SwitchInputMapper::getSources() returns 0 which cannot match any source mask including AINPUT_SOURCE_ANY. As a result initial lid switch detection is broken. This change adds a new source constant AINPUT_SOURCE_SWITCH that indicates that the source has switches. Change-Id: I5321ecf0ce84f1c2b4535f6c163d3f4dcf9b7a9b
/frameworks/base/services/input/tests/InputReader_test.cpp
|
fe50892af3b365806a767298dfd8e86447682581 |
|
19-Jan-2011 |
Jeff Brown <jeffbrown@google.com> |
Filter virtual keys after touches. Adds a new virtualKeyQuietTimeMillis configuration resource that sets the duration for which virtual keys will be dropped after recent touches on screen. The default value is 0; it is intended to be overridden per device using a resource overlay. This change is designed to help in two cases: 1. Swipes from touchscreen into virtual key area. 2. Accidental taps in virtual key area while using on-screen keyboard. Bug: 3089163 Change-Id: Ib912d4f8a4df9966a39cd537d3ec7c24afab7225
/frameworks/base/services/input/tests/InputReader_test.cpp
|
928e054931d357326613c78e62f4d850b7c442ff |
|
10-Jan-2011 |
Jeff Brown <jeffbrown@google.com> |
Prevent events from getting backlogged. This change implements two heuristics. 1. When events are older than 10 seconds, they are dropped. 2. If the application is currently busy processing an event and the user touches a window belonging to a different application then we drop the currently queued events so the other application can start processing the gesture immediately. Note that the system takes care of synthesizing cancelation events automatically for any events that it drops. Added some new handle types to allow the native dispatcher to indirectly refer to the WindowManager's window state and app window token. This was done to enable the dispatcher to identify the application to which each window belongs but it also eliminates some lookup tables and linear searches through the window list on each key press. Bug: 3224911 Change-Id: I9dae8dfe23d195d76865f97011fe2f1d351e2940
/frameworks/base/services/input/tests/InputReader_test.cpp
|
b4ff35df5c04aec71fce7e90a6d6f9ef7180c2ad |
|
03-Jan-2011 |
Jeff Brown <jeffbrown@google.com> |
Mouse pointer integration. Added support for loading the pointer icon from a resource. Moved the system server related bits of the input manager out of libui and into libinput since they do not need to be linked into applications. Change-Id: Iec11e0725b3add2b905c51f8ea2c3b4b0d1a2d67
/frameworks/base/services/input/tests/InputReader_test.cpp
|