Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Replace Android default webview

I want to implement my own webview and replace Android default webview with my implementation (i mean that all applications which uses webview widget will be rendered using my implementation). Is there a way to do that? I would like to hear your advice.

like image 657
Xuân-Lợi Vũ Avatar asked Jul 27 '26 10:07

Xuân-Lợi Vũ


1 Answers

In your own build of Android from AOSP Marshmallow and Lollipop, you can change the value of config_webViewPackageName variable in frameworks/base/core/res/res/values/config.xml (source) to point to your WebView implementation package.

Note that despite the fact that WebView comes in its own apk, it is still part of the framework, so it can't be replaced with some other implementation on existing devices. It's similar to asking "how can I replace the default TextView".

like image 93
Mikhail Naganov Avatar answered Jul 30 '26 08:07

Mikhail Naganov



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!