New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 919432 link

Starred by 2 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Task



Sign in to add a comment

Task: Remove ContentBrowserClient::{NavigationRequestStarted, NavigationRequestRedirected}

Project Member Reported by arthurso...@chromium.org, Jan 7

Issue description

In content/public, there is two ways to act on a new navigation:

1) The "new" ones that are NavigationHandle based. You just need to implement either a WebContentsObserver or a NavigationThrottle. Then you act on the NavigationHandle.

2) The "legacy" ones where you implement the ContentBrowserClient:
ContentBrowserClient::NavigationRequestStarted()
ContentBrowserClient::NavigationRequestRedirected()
The latter are used to modify request headers and load flags.

This bug tracks progress in removing 2) in favor of 1).

 
Project Member

Comment 1 by bugdroid1@chromium.org, Jan 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f8a7e529d9e501a6f43a4cfdd09916a6e8ee4102

commit f8a7e529d9e501a6f43a4cfdd09916a6e8ee4102
Author: Arthur Sonzogni <arthursonzogni@chromium.org>
Date: Fri Jan 11 14:30:14 2019

Modify headers from the NavigationHandle.

In content/public, there is two ways to act on a new navigation:

1) The "new" ones that are NavigationHandle based. Users of the API needs
   to implement either a WebContentsObserver or a NavigationThrottle.
   Then, they can act on the NavigationHandle.

2) The "legacy" ones where you implement the ContentBrowserClient:
   ContentBrowserClient::NavigationRequestStarted()
   ContentBrowserClient::NavigationRequestRedirected()
   The latter are used to modify request headers and load flags.

The goal is to remove 2) and keep only 1)

This CL is making able to modify headers from the NavigationHandle. Following
CL will deprecate and then remove 2).

Bug: 919432
Change-Id: I4db812d4cf1df2f67cf8bf97dca410009a1a3046
Reviewed-on: https://chromium-review.googlesource.com/c/1392949
Reviewed-by: Camille Lamy <clamy@chromium.org>
Commit-Queue: Arthur Sonzogni <arthursonzogni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#621997}
[modify] https://crrev.com/f8a7e529d9e501a6f43a4cfdd09916a6e8ee4102/content/browser/frame_host/navigation_handle_impl.cc
[modify] https://crrev.com/f8a7e529d9e501a6f43a4cfdd09916a6e8ee4102/content/browser/frame_host/navigation_handle_impl.h
[modify] https://crrev.com/f8a7e529d9e501a6f43a4cfdd09916a6e8ee4102/content/browser/frame_host/navigation_request.cc
[modify] https://crrev.com/f8a7e529d9e501a6f43a4cfdd09916a6e8ee4102/content/browser/navigation_browsertest.cc
[modify] https://crrev.com/f8a7e529d9e501a6f43a4cfdd09916a6e8ee4102/content/public/browser/content_browser_client.h

Sign in to add a comment