如何启用的Android应用程序WebKit的远程调试/检查使用的WebView? [英] how to enable WebKit's remote debugging/inspector of Android app using WebView?
问题描述
我需要检查JavaScript执行(的WebView小部件)的Android应用程序, 在调试;通过SDK和放大器; USB电缆和/或http /的WebSockets; 从destop电脑(台式机如Chrome中运行)。
I need to inspect javascript execution (webview widget) in an android application, while debugging; through SDK & usb cable and/or http/websockets; from destop computer (e.g. chrome running on desktop).
WebKit的来源包括DebuggerServer实施 (platform_external_webkit \来源\ WebKit的\机器人\ WDS \ DebugServer.cpp) 在访问CPP水平,并绑定如果标志WDS启用(在制作的时候?)
Webkit's sources includes DebuggerServer implementation ( platform_external_webkit\Source\WebKit\android\wds\DebugServer.cpp ) accessible at cpp level, and bound if flag WDS is enabled (at build time?)
来源\ WebKit的\机器人\ JNI \ WebCoreFrameBridge.cpp:#如果使能(WDS) 来源\ WebKit的\机器人\ JNI \ WebCoreFrameBridge.cpp:WDS ::服务器() - > ADDFRAME(架);
Source\WebKit\android\jni\WebCoreFrameBridge.cpp:#if ENABLE(WDS) Source\WebKit\android\jni\WebCoreFrameBridge.cpp: WDS::server()->addFrame(frame);
有关服务器的默认端口为9999。
The default port for server is 9999
来源显示,所有被实施(在.cpp的水平),以启用该功能, 但我还没有发现任何参考在网上搜索的体验 使用实时调试在的Adroid设备自动化的JavaScript水平 WebKit的检查界面。
The sources show that all is implemented (at Cpp level) to enable the feature, but I have not found any reference searching the web for experiences using live debugging at javascript level in adroid devices automating webkit's inspector interface.
1:是功能present,以二进制形式,在执行实际的Android设备? (已建成的WebKit的Adroid的分布,而不启用WDS标志?:-()
1.- Are the feature present, in binary form, executing in actual android devices? (has adroid's distribution of webkit been built without WDS flag enabled? :-( )
2:可远程调试功能启用/使用的JavaScript或应用程序 (在Java级别)如在应用程序启动?
2.- Can the remote debug feature be enabled/used from javascript or application (at java level) e.g. at startup of app?
3 .-情况下,它有可能使WebKit的检查/调试器的功能, 如何使有可能从远程应用程序交互? (例如,从 另一个JavaScript应用程序中使用的WebSockets,或铬在桌面计算机上)。
3.- In case it is possible to enable the webkit inspector/debugger feature, how to make it possible to interact from remote application ? (e.g. from another javascript app using websockets, or chrome on desktop computers).
有些段落解释类似的机制 <一href="https://developers.google.com/chrome-developer-tools/docs/remote-debugging#remote">https://developers.google.com/chrome-developer-tools/docs/remote-debugging#remote 将是很好!
Some paragraphs explaining the mechanics like https://developers.google.com/chrome-developer-tools/docs/remote-debugging#remote would be nice!
感谢您的任何信息,或参考有关此主题。 我认为重要的是要启用远程调试(在设备中)在 JavaScript的水平,使HTML5的可能现代发展 应用和快乐的调试经验。
thanks in advance for any information, or references about this topic. I consider important to enable remote debugging (in the device) at javascript level to make it possible modern development of HTML5 applications and happy debugging experience.
欢呼声, 啤酒。
推荐答案
现在很容易与Android 4.4。见的https://developers.google.com/chrome-developer-tools/docs/remote-debugging#debugging-webviews
Now it is easy with Android 4.4. See https://developers.google.com/chrome-developer-tools/docs/remote-debugging#debugging-webviews
这篇关于如何启用的Android应用程序WebKit的远程调试/检查使用的WebView?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!