
In crrev.com/c/5439512, we introduced "navigation listeners", where WebView clients can inject special objects that can listen to navigation events. In this CL, we add the ability for the client to request to disable BFCache, ensuring all pages can't be BFCached. We provide this functionality so that if the client can't handle BFCache yet (due to needing to update client-side code to handle reusing pages, etc) while the BFCache flag is already enabled on the WebView side (e.g. during random experimentation), it won't get confused with the ordering of events (e.g. PAGE_DELETED not getting called for a long time). Now the client can use one of these 2 navigation listeners: - experimentalWebViewNavigationListenerDisableBFCache: Will listen to messages and also prevent any page from getting BFCached. - experimentalWebViewNavigationListenerAllowBFCache: Will listen to messages and not prevent pages from getting BFCached. But BFCache can still be disabled by the WebView/other reasons. See doc & comment for more details & motivation: - https://docs.google.com/document/d/1mF1MGsKnwnJ8EwG8GpzcewEcC3NOOuetILuZSevU35Q/edit?tab=t.0#heading=h.uh8ofbnx6z0u - https://chromium-review.googlesource.com/c/chromium/src/+/5439512/comment/459e7e82_048d4fa6/ Bug: 332809183 Change-Id: I05a6d89cac90537a9043672111a219eefd0f1357 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5470130 Commit-Queue: Rakina Zata Amni <rakina@chromium.org> Reviewed-by: Scott Violet <sky@chromium.org> Reviewed-by: Andrey Kosyakov <caseq@chromium.org> Reviewed-by: Richard (Torne) Coles <torne@chromium.org> Cr-Commit-Position: refs/heads/main@{#1291747}
Android WebView
Android WebView is an Android system component for displaying web content.
WebView (and
the related Android classes) are implemented by the code in the
//android_webview/
folder.
This directory contains the Android WebView implementation, as well as the implementation for the AndroidX Webkit support library.
Overview for Chromium team members and contributors
Please see WebView Architecture.
Want to use WebView in an Android app?
Please consult our API documentation and app development guides:
Want to build and install WebView on a device?
See our Chromium developer documentation.
Public mailing lists
- android-webview-dev@chromium.org: external discussion group for WebView developers and interested community members.
- android-webview-reviews@chromium.org: subscribe to code reviews affecting Android WebView code.