android中置调用指定浏览器
16lz
2021-01-24
android中置调用指定浏览器
更多信息请访问 java教程网www.itchm.com
默认的浏览器都列出让用户选择的
Java代码
Uri u = Uri.parse(url);
Intent it = new Intent(Intent.ACTION_VIEW, url); TestActivity.this.startActivity(it);
Uri u = Uri.parse(url);
Intent it = new Intent(Intent.ACTION_VIEW, url); TestActivity.this.startActivity(it);
指定浏览器的
Java代码
Uri u = Uri.parse(url);
it.setData(u);
it.setAction( Intent.ACTION_VIEW);
it.setClassName("com.android.browser","com.android.browser.BrowserActivity");
TestActivity.this.startActivity(it);
更多信息请访问 java教程网www.itchm.com
更多相关文章
- Android获得SD卡剩余容量的源码
- android 随手记 videoview循环播放网络视频 和mediaplayer+sufac
- 系出名门Android(6) - 控件(View)之DatePicker, TimePicker, Tog
- android 震动的api介绍
- Android(安卓)json数据解析详解及实例代码
- 写下关于popwindow
- Android(安卓)ToolBar
- Android(安卓)实例教程
- ANDROID 自动接听 支持2.3以上版本