您的位置:首页 > 其它

unable to connect to the adb. check if adb is installed correctly

2013-02-17 15:23 651 查看
from:https://plus.google.com/108487870030743970488/posts/2TrMqs1ZGQv

Endian Ogino

2012-11-17 - 公开

My first experience with the new uiautomatorviewer:

"unable to connect to the adb. check if adb is installed correctly"

Challenge Accepted:

1. ScreenshotAction class has this in its run() method when !DebugBridge.isInitialized()

2. DebugBridge is not initialized when it can't find the "platform-tools" folder which it gets via the property ""com.android.uiautomator.bindir"

3. The above property is set (in windows) in uiautomatorviewer.bat:

call %java_exe% -Djava.ext.dirs=%javaextdirs% -Dcom.android.uiautomator.bindir= -jar %jarpath% %*

4. Strange that it is empty isn't it. Changing the above line in my case to:

call %java_exe% -Djava.ext.dirs=%javaextdirs% -Dcom.android.uiautomator.bindir=H:\android-sdk\tools -jar %jarpath% %*

This solves the issue, and UI Automator Viewer is up. The app is pretty neat with all the "mouse over"-"find view" feature.



内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐