[AC-1584] Enter Key Not Captured in Android Emulator
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Resolved |
Resolution | Invalid |
Resolution Date | 2015-09-29T05:02:39.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | Studio |
Labels | n/a |
Reporter | Charles Assaf |
Assignee | Shak Hossain |
Created | 2015-03-13T08:23:25.000+0000 |
Updated | 2016-03-08T07:38:03.000+0000 |
Description
Trying to capture the Return key in a listener in a view that works correctly under SDK 3.5.0 GA. Event is not firing in 3.5.1 GA, and the following is appearing in the console log:
[DEBUG] : InputEventConsistencyVerifier: KeyEvent: ACTION_UP but key was not down.
[DEBUG] : InputEventConsistencyVerifier: in org.appcelerator.titanium.view.TiCompositeLayout{b1aa6738 V.E...CL ......I. 0,0-1080,0 #b}
[DEBUG] : InputEventConsistencyVerifier: 0: sent at 249134000000, KeyEvent { action=ACTION_UP, keyCode=KEYCODE_ENTER, scanCode=28, metaState=0, flags=0x8, repeatCount=0, eventTime=249134, downTime=249022, deviceId=0, source=0x101 }
[DEBUG] : InputEventConsistencyVerifier: -- recent events --
[DEBUG] : InputEventConsistencyVerifier: 1: sent at 101154000000, KeyEvent { action=ACTION_UP, keyCode=KEYCODE_ENTER, scanCode=28, metaState=0, flags=0x80000008, repeatCount=0, eventTime=101154, downTime=101074, deviceId=0, source=0x101 }
[DEBUG] : InputEventConsistencyVerifier: 2: sent at 76383000000, KeyEvent { action=ACTION_UP, keyCode=KEYCODE_ENTER, scanCode=28, metaState=0, flags=0x80000008, repeatCount=0, eventTime=76383, downTime=76191, deviceId=0, source=0x101 }
[DEBUG] : InputEventConsistencyVerifier: 3: sent at 72522675000, MotionEvent { action=ACTION_UP, id[0]=0, x[0]=270.0, y[0]=450.0, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=0, eventTime=72522, downTime=72426, deviceId=0, source=0x1002 }
[DEBUG] : InputEventConsistencyVerifier: 4: sent at 72426934000, MotionEvent { action=ACTION_DOWN, id[0]=0, x[0]=270.0, y[0]=450.0, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=0, eventTime=72426, downTime=72426, deviceId=0, source=0x1002 }
[DEBUG] : InputEventConsistencyVerifier: 5: sent at 66990566000, MotionEvent { action=ACTION_UP, id[0]=0, x[0]=998.0, y[0]=140.0, toolType[0]=TOOL_TYPE_FINGER, buttonState=0, metaState=0, flags=0x0, edgeFlags=0x0, pointerCount=1, historySize=0, eventTime=66990, downTime=66894, deviceId=0, source=0x1002 }
Recent events in trace clearly indicate that an ACTION_DOWN MotionEvent was fired prior to the ACTION_UP event.
Update. This issue does actually occur in SDK 3.5.0 GA. Further to this, it only seems to happen if the soft keyboard is not displayed (and using the hardware keyboard). If I enable the display of the soft keyboard via Android Input Device settings, the emulator correctly returns the Enter (Return) key when it is pressed on the hardware keyboard, so not really sure if this is an Android or a Titanium issue.
Hello [~doncarlos], We tested your issue . Its a native emulator settings issue. Thanks