| Index: content/browser/frame_host/navigation_handle_impl.cc
|
| diff --git a/content/browser/frame_host/navigation_handle_impl.cc b/content/browser/frame_host/navigation_handle_impl.cc
|
| index 316bf66638b0475740fb3bea1ff304abc14189a6..df5f3b40b78d7fdc089171c875cf7146c11135a9 100644
|
| --- a/content/browser/frame_host/navigation_handle_impl.cc
|
| +++ b/content/browser/frame_host/navigation_handle_impl.cc
|
| @@ -246,20 +246,30 @@ NavigationHandleImpl::CallWillRedirectRequestForTesting(
|
| WillRedirectRequest(new_url, new_method_is_post, new_referrer_url,
|
| new_is_external_protocol,
|
| scoped_refptr<net::HttpResponseHeaders>(),
|
| base::Bind(&UpdateThrottleCheckResult, &result));
|
|
|
| // Reset the callback to ensure it will not be called later.
|
| complete_callback_.Reset();
|
| return result;
|
| }
|
|
|
| +bool NavigationHandleImpl::IsUsingLofi() const {
|
| + DCHECK(state_ == DID_COMMIT || state_ == DID_COMMIT_ERROR_PAGE);
|
| + return is_using_lofi_;
|
| +}
|
| +
|
| +bool NavigationHandleImpl::UsedDataReductionProxy() const {
|
| + DCHECK(state_ == DID_COMMIT || state_ == DID_COMMIT_ERROR_PAGE);
|
| + return used_data_reduction_proxy_;
|
| +}
|
| +
|
| void NavigationHandleImpl::InitServiceWorkerHandle(
|
| ServiceWorkerContextWrapper* service_worker_context) {
|
| DCHECK(IsBrowserSideNavigationEnabled());
|
| service_worker_handle_.reset(
|
| new ServiceWorkerNavigationHandle(service_worker_context));
|
| }
|
|
|
| void NavigationHandleImpl::WillStartRequest(
|
| bool is_post,
|
| const Referrer& sanitized_referrer,
|
| @@ -366,20 +376,22 @@ void NavigationHandleImpl::DidCommitNavigation(
|
| RenderFrameHostImpl* render_frame_host) {
|
| DCHECK(!render_frame_host_ || render_frame_host_ == render_frame_host);
|
| DCHECK_EQ(frame_tree_node_, render_frame_host->frame_tree_node());
|
| CHECK_EQ(url_, params.url);
|
|
|
| is_post_ = params.is_post;
|
| has_user_gesture_ = (params.gesture == NavigationGestureUser);
|
| transition_ = params.transition;
|
| render_frame_host_ = render_frame_host;
|
| is_same_page_ = same_page;
|
| + is_using_lofi_ = params.is_using_lofi;
|
| + used_data_reduction_proxy_ = params.used_data_reduction_proxy;
|
|
|
| state_ = net_error_code_ == net::OK ? DID_COMMIT : DID_COMMIT_ERROR_PAGE;
|
| }
|
|
|
| NavigationThrottle::ThrottleCheckResult
|
| NavigationHandleImpl::CheckWillStartRequest() {
|
| DCHECK(state_ == WILL_SEND_REQUEST || state_ == DEFERRING_START);
|
| DCHECK(state_ != WILL_SEND_REQUEST || next_index_ == 0);
|
| DCHECK(state_ != DEFERRING_START || next_index_ != 0);
|
| for (size_t i = next_index_; i < throttles_.size(); ++i) {
|
|
|