android webview实现唤起qq临时会话
16lz
2022-06-18
安卓部分代码
页面html代码
class MyWebviewclient extends WebViewClient {@Overridepublic void onPageStarted(WebView view, String url, android.graphics.Bitmap favicon) {if (url.startsWith("mqqwpa")) {view.stopLoading();Intent in = new Intent(Intent.ACTION_VIEW, Uri.parse(url));startActivity(in);}else{super.onPageStarted(view, url, favicon);}}} WebViewClient mWebViewClient = new MyWebviewclient();webView.setWebViewClient(mWebViewClient);
页面html代码
location.href="mqqwpa://im/chat?chat_type=wpa&uin=954502368";
更多相关文章
- Android之十三图片2D翻转
- Android(安卓)屏幕截图 代码
- Android(安卓)开发常用代码片段
- android 拨打电话
- recovery代码流程
- Android(安卓)Studio配置Android(安卓)annotation(注解)
- Android腾讯微薄客户端开发十四:首页menu菜单
- 操作内存卡的常用代码
- Android(安卓)Studio使用AIDL时无法找到自定义的类