-
Hiroki Nakagawa authored
This CL avoids starting navigation for prerendering when it already started for the same URL. To do that, this moves PrerenderHost::StartNavigation() call into PrerenderHostRegistry::RegisterHost(). This doesn't change behavior around networking. Even before this change, the duplicate navigation didn't issue a network request because PrerenderHost was destroyed right after PrerenderHost::StartNavigation() was called. The browser tests make sure this behavior. In addition to that, this change renames RegisterHost() to CreateAndStartHost() and then moves the PrerenderHost creation into the function for code cleanup. Bug: 1132746 Change-Id: Ibc1d51921d845c2746a1a0caca27e08e77256699 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2567514Reviewed-by:
Matt Falkenhagen <falken@chromium.org> Reviewed-by:
Takashi Toyoshima <toyoshim@chromium.org> Commit-Queue: Hiroki Nakagawa <nhiroki@chromium.org> Cr-Commit-Position: refs/heads/master@{#833583}
8f6a95d8