在通过故意Android浏览器打开和关闭浏览器标签?关闭浏览器、浏览器、标签、Android

2023-09-03 22:44:21 作者:好好过生活

我知道我可以在浏览器中的一个Android应用程序使用的是意图在新标签中打开一个URL。

I know I can open a URL in a new tab in a browser from an android app using an intent.

但是,有没有好办法,也结束了我的应用程序之前已经开了这样的标签?

But is there a good way to also close such a tab that my app has opened before?

推荐答案

没有,对不起。没有标准意图结构这一点。虽然它可能是一些浏览器提供的东西,我不知道任何事情。

No, sorry. There is no standard Intent structure for this. While it is possible that some browsers offer something, I am not aware of any that do.

请记住,有没有需求,你的 ACTION_VIEW 意图打开浏览器的标签的,作为用户选择的浏览器可能不提供任何形式的标签的UI隐喻

Bear in mind that there is no requirement that your ACTION_VIEW Intent open up a browser tab, as the user's chosen browser may not offer any sort of tab UI metaphor.

 
精彩推荐
图片推荐