diff options
author | Siarhei Vishniakou <svv@google.com> | 2018-10-30 14:04:57 -0700 |
---|---|---|
committer | Siarhei Vishniakou <svv@google.com> | 2019-02-26 13:22:24 -0800 |
commit | ccf973fa9f22dbafe7e98952773ec2dc2b3e90a5 (patch) | |
tree | 822b1e73877365cb9237bfa9356405932e4eb9ec /cmds/input/src | |
parent | 983469bab51743f044a62a72182ffc7b60b1a7a2 (diff) |
Inject long press documentation
Clarify usage of Activity.onKeyLongPress(..). It is not obvious at
all that onKeyDown should be used in order for OnKeyLongPress to work.
Direct readers to the other api to make sure that this nuance is not
missed.
Bug: 21451760
Test: atest KeyEventInjectionTest
Change-Id: Ic73f6fe06b2108a3967ac590d22acfb283a700e1
Diffstat (limited to 'cmds/input/src')
-rw-r--r-- | cmds/input/src/com/android/commands/input/Input.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmds/input/src/com/android/commands/input/Input.java b/cmds/input/src/com/android/commands/input/Input.java index 0c861cfd3e63..a0777459311b 100644 --- a/cmds/input/src/com/android/commands/input/Input.java +++ b/cmds/input/src/com/android/commands/input/Input.java @@ -196,7 +196,7 @@ public class Input extends BaseCommand { int repeatCount = 0; KeyEvent event = new KeyEvent(now, now, KeyEvent.ACTION_DOWN, keyCode, repeatCount, - 0 /*metaState*/, KeyCharacterMap.VIRTUAL_KEYBOARD, 0 /*scancode*/, 0/*flags*/, + 0 /*metaState*/, KeyCharacterMap.VIRTUAL_KEYBOARD, 0 /*scancode*/, 0 /*flags*/, inputSource); event.setDisplayId(displayId); |