diff options
author | Chao Yan <aceyansf@google.com> | 2018-05-22 17:05:09 -0700 |
---|---|---|
committer | Chao Yan <aceyansf@google.com> | 2018-05-23 17:47:02 -0700 |
commit | c7f46a9104419e071302adcb2a5908177b9fd41c (patch) | |
tree | 107f07cec320000ea8aa544a679f6b51838b92f2 /tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink | |
parent | 9a5e4d474d26d3c4cc7b143d111ef29a404c0621 (diff) | |
download | Car-c7f46a9104419e071302adcb2a5908177b9fd41c.tar.gz |
Fixed inconsistent KeyPress command in Kitchen Sink
Bug: 76017041
Test: build and flash on Mojave; open Input Test in Kitchen Sink and
verify it can inject key code
Change-Id: I3f108293c9fdce60d495f5fc301d3117cc91c911
Merged-In: I3f108293c9fdce60d495f5fc301d3117cc91c911
Diffstat (limited to 'tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink')
-rw-r--r-- | tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/input/InputTestFragment.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/input/InputTestFragment.java b/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/input/InputTestFragment.java index 4b9ec1d25b..2c1beb42f1 100644 --- a/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/input/InputTestFragment.java +++ b/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/input/InputTestFragment.java @@ -41,8 +41,6 @@ import android.widget.LinearLayout; import android.widget.TextView; import android.widget.Toast; -import android.support.v4.app.Fragment; - import com.android.car.keventreader.EventReaderService; import com.android.car.keventreader.IEventCallback; import com.android.car.keventreader.KeypressEvent; @@ -67,10 +65,12 @@ public class InputTestFragment extends Fragment { private final List<View> mButtons = new ArrayList<>(); - // This is special property available only in emulated VHAL implementation. + // This is fake data generation property available only in emulated VHAL implementation. private static final int sGenerateFakeDataControllingProperty = 0x0666 | VehiclePropertyGroup.VENDOR | VehicleArea.GLOBAL | VehiclePropertyType.MIXED; - private static final int sKeyPressCommand = 2; + // The key press command is sent with the fake data generation property. It's matching the + // command defined in the emulated VHAL implementation. + private static final int sKeyPressCommand = 100; private IVehicle mVehicle; |