Receive owned copy of KeyCharacterMap in InputDevice

To prevent incorrect usage of the KeyCharacterMap API's, transfer the
ownership of the native KeyCharacterMap object when creating the java
KCM object.

Bug: 274058082
Test: presubmit
Change-Id: I8e412de1791d5bb874ee709441ea12028d64857c
3 files changed