Reputation: 4054
This is kind of a shot in the dark, but... I know we have WebView
exposed. I was wondering if there is anyway we could use / embed firefox's renderer in an Android app?
I have an .mht
file which neither works in androids default browser, dolphin, or opera. But mysteriously works in firefox mobile.
Is there any way this is possible?
Upvotes: 2
Views: 6823
Reputation: 25755
So, the "features"-site of the mobile Firefox reads:
The mobile Firefox is built on the same browser engine as the desktop version, yet optimized for browsing on a mobile device.
Since the desktop-version of Firefox uses Mozilla's own Gecko-engine for rendering, this will be it.
There are docs on how to embed the Gecko engine in your project (and an older question: How can I embed firefox in a GUI application?), but those target the use in desktop-applications (which normally have more resources for use) and are not available as a Java library/binding.
Since Mozilla is an OpenSource-company, the sources for the Mobile Firefox are public and build-instructions can be found here. Although you can play around with it and see if you can isolate only the rendering-engine part to use it in your application.
Another option would be putting all those files (which are bundled in your .mht
-file) in the /res/raw
-folder and use them with a normal WebView
.
Upvotes: 3