Pick up device configuration "device.internal = 0". Before, only "device.internal = 1" had an effect.
Change-Id: Ie88ed66e0841418c147bed2e23806405bdd17ad6
diff --git a/services/input/EventHub.cpp b/services/input/EventHub.cpp
index 1d7cc19..06dea36 100644
--- a/services/input/EventHub.cpp
+++ b/services/input/EventHub.cpp
@@ -1094,9 +1094,8 @@
bool EventHub::isExternalDeviceLocked(Device* device) {
if (device->configuration) {
bool value;
- if (device->configuration->tryGetProperty(String8("device.internal"), value)
- && value) {
- return false;
+ if (device->configuration->tryGetProperty(String8("device.internal"), value)) {
+ return !value;
}
}
return device->identifier.bus == BUS_USB || device->identifier.bus == BUS_BLUETOOTH;