android - 向 Android 模拟器发送多点触控事件

标签 android android-emulator multi-touch

我需要测试一个采用多点触控输入(例如捏合和旋转)的 Android 应用程序。如果可能的话,我想用模拟器来测试一下。有没有办法在不修改 Android 源代码的情况下通过 ADB 或其他方式发送 Linux 输入事件?

https://source.android.com/devices/tech/input/touch-devices.html

ABS_MT_POSITION_X、ABS_MT_POSITION_Y 和 ABS_MT_TRACKING_ID 等事件。

最佳答案

老问题,但仍然悬而未决。 确实有选择:

1.) 通过 telnet ( https://developer.android.com/studio/run/emulator-console ) 发送命令

2.) 像使用 adb(输入 tap X Y),例如

adb shell input tap 100 100

关于android - 向 Android 模拟器发送多点触控事件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21731514/

相关文章:

android - android模拟器会在主机上使用vpn访问网络吗

android-emulator - Genymotion“与虚拟设备的连接已丢失。

Android测试,如何使用仪器模拟多点触控(放大/缩小)?

security - 来自随机放置的圆圈的随机字符串

Android MotionEvent 只检测 ACTION_MOVE

android - 如何在 Android 上创建 youtube 的双击手势?

Android依赖 'com.android.support:support-v4'有不同的版本

android - 如何在 Android 的 WebView 中加载 url 以正确查看?

安卓 : How to repeat a Toast every second

android - 如何查看变化的集合?