diff options
author | Jeff Brown <jeffbrown@google.com> | 2010-09-23 13:51:48 -0700 |
---|---|---|
committer | Jeff Brown <jeffbrown@google.com> | 2010-09-23 13:56:30 -0700 |
commit | 93ed4e3052a773289c0570984801ea8f0f0849d2 (patch) | |
tree | 3a3aa1f29bb6ad6228cc71ac337ee68ca0fd7225 /policy/src | |
parent | 37cedce14bc0e68e8bf27c2cecb181728226e6ed (diff) | |
download | frameworks_base-93ed4e3052a773289c0570984801ea8f0f0849d2.zip frameworks_base-93ed4e3052a773289c0570984801ea8f0f0849d2.tar.gz frameworks_base-93ed4e3052a773289c0570984801ea8f0f0849d2.tar.bz2 |
Enforce serial ordering of MotionEvents.
This change modifies ViewRoot to wait until the MotionEvent has been
delivered before telling the input dispatcher that it is finished.
The serial ordering guarantee will be required by new features that
may need to transfer touch focus from one window to another.
Change-Id: I0a64d1f0c8bc3f08846f213d6e28ce48b1d48e58
Diffstat (limited to 'policy/src')
-rwxr-xr-x | policy/src/com/android/internal/policy/impl/PhoneWindowManager.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java index 274124b..567b270 100755 --- a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java +++ b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java @@ -232,8 +232,11 @@ public class PhoneWindowManager implements WindowManagerPolicy { @Override public void handleMotion(MotionEvent event, Runnable finishedCallback) { finishedCallback.run(); + synchronized (mLock) { - mPointerLocationView.addTouchEvent(event); + if (mPointerLocationView != null) { + mPointerLocationView.addTouchEvent(event); + } } } }; |