I'm writing a small Android game and am using the WebView for reading an HTML file from the packed resources.

If the packed HTML file does not reference any resources on the Internet, do I still need to include Internet access in the permissions file?

有帮助吗?

解决方案

No, according to the docs the internet permission is only required for using sockets. You can read in the HTML data into a String and use the loadData function.

其他提示

No, it should be safe to access file:// w/o internet permission as long as your content (html file) does not need anything from the net (like remote images). And one note though: it would take you much less time to test that yourself than you spent asking here.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top