WebLayer: Use RedirectHandlerImpl
This CL augments WebLayer's external intent launching to use the RedirectHandler implementation that is used by Chrome. This takes another step in bringing WebLayer's external intent launching logic up to par with Chrome's; in particular, see the tests modified in this CL, which highlight areas that had previously been deficient in WebLayer. There is one subtlety in this bringup: RedirectHandlerImpl wants to know the last time that the user interacted with the app as a heuristic to help determine if a navigation was started by the user. In Chrome this is determined by the Activity subclass listening for user interaction. However in WebLayer this information is not available, as WebLayer's Activity is provided by the client and thus opaque. Instead, this CL uses a replacement heuristic wherein we pass a user interaction time to RedirectHandlerImpl that is updated on navigations that are either from user typing or have a user gesture associated with them. To date, we have not seen any differences that would result from the usage of these different heuristics. Bug: 1031465, 1066291 Change-Id: Ia9b2c94433db61eb743bfdd50caa9f99fc699c46 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2130790 Commit-Queue: Colin Blundell <blundell@chromium.org> Reviewed-by:Michael Thiessen <mthiesse@chromium.org> Cr-Commit-Position: refs/heads/master@{#757774}
Showing
Please register or sign in to comment