Android DevCamp Produced by CSDN Website: http://devcamp.csdn.net/ Weibo: http://weibo.com/cmdnclub/
Android
APP - - -
[ ]
Android 1.6 2.3.2 2012-7-11
[ ]
[ ]
[ ]
[ ]
[ ]
[ ]
Native App +
Web App
Native App
[ ]
Web App
WebView WebkitSDK JavaJavaScriptWebView
[ ]
[ ]
NativeWeb loadUrl
webview.loadUrl(" m.vancl.com ");
loadDataWithBaseURL
webview.loadDataWithBaseURL(String baseUrl,
String data, String mimeType,
String encoding, String failUrl);
[ ]
WebNative addJavascriptInterface
webview. addJavascriptInterface(Object obj, String terfaceName);
Nativewebview. addJavascriptInterface (this, VanclAct); WebJavascript:window.VanclAct.redirect(); NativeBaseActivity.redirect() { };
[ ]
WebNative Web webview.loadDataWithBaseURL(null, homeBean.content, "text/html", "utf-8", null);!
[ ]
Web webview.loadUrl(m.vancl.com); Native Web Web NativeNativewebview. addJavascriptInterface (this, VanclAct); WebJavascript:window.VanclAct.redirect(); NativeBaseActivity.redirect() { };
[ ]
,
[ ]
abort() Timeout
[ ]
res
[ ]
[ ]
21
2012728!