InputDevice = android.view.InputDevice;
inputManager = android.os.ServiceManager.getService("input");
deviceIds = inputManager.getInputDeviceIds();
touchDeviceId = -1;
for (i = 0; i < deviceIds.length; i++) {
id = deviceIds[i];
sources = inputManager.getInputDevice(id).getSources();
if ((sources & InputDevice.SOURCE_TOUCHSCREEN) == InputDevice.SOURCE_TOUCHSCREEN) {
touchDeviceId = id;
}
}
inputManager.enableInputDevice(touchDeviceId);
// 设置启用屏幕触摸#MVEL表达式 #Javascript