summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Wright <michaelwr@google.com>2014-09-24 13:26:59 -0700
committerMichael Wright <michaelwr@google.com>2014-09-25 13:20:20 -0700
commit2e732956adffbdf37374115d52646ddae9498a96 (patch)
tree5f18b9f5b8b8164e6614f7ed5c7fb886fd17fcbc
parent5105960d49bfa86efeeea8f87c87aa96b5771c37 (diff)
downloadframeworks_native-2e732956adffbdf37374115d52646ddae9498a96.zip
frameworks_native-2e732956adffbdf37374115d52646ddae9498a96.tar.gz
frameworks_native-2e732956adffbdf37374115d52646ddae9498a96.tar.bz2
Only mark repeated keys as PASS_TO_USER if the original key was.
Bug: 17629695 Change-Id: Ic569aba4149c6cc321c2cf8aede7c5e8a1196234
-rw-r--r--services/inputflinger/InputDispatcher.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/services/inputflinger/InputDispatcher.cpp b/services/inputflinger/InputDispatcher.cpp
index ce14f99..2b5e744 100644
--- a/services/inputflinger/InputDispatcher.cpp
+++ b/services/inputflinger/InputDispatcher.cpp
@@ -653,8 +653,8 @@ InputDispatcher::KeyEntry* InputDispatcher::synthesizeKeyRepeatLocked(nsecs_t cu
KeyEntry* entry = mKeyRepeatState.lastKeyEntry;
// Reuse the repeated key entry if it is otherwise unreferenced.
- uint32_t policyFlags = (entry->policyFlags & POLICY_FLAG_RAW_MASK)
- | POLICY_FLAG_PASS_TO_USER | POLICY_FLAG_TRUSTED;
+ uint32_t policyFlags = entry->policyFlags &
+ (POLICY_FLAG_RAW_MASK | POLICY_FLAG_PASS_TO_USER | POLICY_FLAG_TRUSTED);
if (entry->refCount == 1) {
entry->recycle();
entry->eventTime = currentTime;