Loading core/jni/android_view_InputDevice.cpp +10 −2 Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ * limitations under the License. */ #include <binder/Parcel.h> #include <input/Input.h> #include <android_runtime/AndroidRuntime.h> Loading Loading @@ -48,9 +49,16 @@ jobject android_view_InputDevice_create(JNIEnv* env, const InputDeviceInfo& devi return NULL; } sp<KeyCharacterMap> map = deviceInfo.getKeyCharacterMap(); if (map != nullptr) { Parcel parcel; map->writeToParcel(&parcel); map = map->readFromParcel(&parcel); } ScopedLocalRef<jobject> kcmObj(env, android_view_KeyCharacterMap_create(env, deviceInfo.getId(), deviceInfo.getKeyCharacterMap())); map)); if (!kcmObj.get()) { return NULL; } Loading Loading
core/jni/android_view_InputDevice.cpp +10 −2 Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ * limitations under the License. */ #include <binder/Parcel.h> #include <input/Input.h> #include <android_runtime/AndroidRuntime.h> Loading Loading @@ -48,9 +49,16 @@ jobject android_view_InputDevice_create(JNIEnv* env, const InputDeviceInfo& devi return NULL; } sp<KeyCharacterMap> map = deviceInfo.getKeyCharacterMap(); if (map != nullptr) { Parcel parcel; map->writeToParcel(&parcel); map = map->readFromParcel(&parcel); } ScopedLocalRef<jobject> kcmObj(env, android_view_KeyCharacterMap_create(env, deviceInfo.getId(), deviceInfo.getKeyCharacterMap())); map)); if (!kcmObj.get()) { return NULL; } Loading