From 49a8e451b8dd4d3708e2dd606bc522de90eed6ed Mon Sep 17 00:00:00 2001 From: "Erick (CptBlackPixel)" Date: Mon, 14 Oct 2019 21:47:15 -0300 Subject: [PATCH] Adding deviceId to KeyEventChannel enconding method (#12958) This Pull Request simple adds the deviceId property to the encoding method, I am preparing a next PR on the flutter repository that reads this info and add a property to RawKeyEventDataAndroid on the Flutter side. This is necessary so we can support multiple gamepads on Android, in order to be possible to make a local multiplayer game with Flutter. --- .../flutter/embedding/engine/systemchannels/KeyEventChannel.java | 1 + 1 file changed, 1 insertion(+) diff --git a/shell/platform/android/io/flutter/embedding/engine/systemchannels/KeyEventChannel.java b/shell/platform/android/io/flutter/embedding/engine/systemchannels/KeyEventChannel.java index c0025e8927f..791191f9bde 100644 --- a/shell/platform/android/io/flutter/embedding/engine/systemchannels/KeyEventChannel.java +++ b/shell/platform/android/io/flutter/embedding/engine/systemchannels/KeyEventChannel.java @@ -60,6 +60,7 @@ public class KeyEventChannel { message.put("source", event.source); message.put("vendorId", event.vendorId); message.put("productId", event.productId); + message.put("deviceId", event.deviceId); } /**