
The WebContentsImpl is the only consumer of this information, and it only cares about the host. URLs can be huge (up to 2MB), while hosts are much much smaller. It isn't a good idea to copy the URL for every outgoing request to the UI thread every 250ms. Note: previously this code did some grouping by RVid (I think) before thread hopping. This would further alleviate copying issues when there are lots of requests. Probably we could just use two sets: 1. Global frame routing id -> LoadInfo for subresources 2. All navigation requests Bug: 813445 Change-Id: Ied3709fac7bba079d5e31694dc8e477d1c7f2f68 Reviewed-on: https://chromium-review.googlesource.com/951364 Reviewed-by: Matt Menke <mmenke@chromium.org> Reviewed-by: Avi Drissman <avi@chromium.org> Commit-Queue: Charlie Harrison <csharrison@chromium.org> Cr-Commit-Position: refs/heads/master@{#541189}
30 lines
898 B
C++
30 lines
898 B
C++
// Copyright 2016 The Chromium Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
// found in the LICENSE file.
|
|
|
|
#ifndef CONTENT_BROWSER_LOADER_DELEGATE_IMPL_H_
|
|
#define CONTENT_BROWSER_LOADER_DELEGATE_IMPL_H_
|
|
|
|
#include <string>
|
|
|
|
#include "content/browser/loader/loader_delegate.h"
|
|
#include "content/common/content_export.h"
|
|
|
|
namespace content {
|
|
|
|
class CONTENT_EXPORT LoaderDelegateImpl : public LoaderDelegate {
|
|
public:
|
|
~LoaderDelegateImpl() override;
|
|
|
|
// LoaderDelegate implementation:
|
|
void LoadStateChanged(WebContents* web_contents,
|
|
const std::string& host,
|
|
const net::LoadStateWithParam& load_state,
|
|
uint64_t upload_position,
|
|
uint64_t upload_size) override;
|
|
};
|
|
|
|
} // namespace content
|
|
|
|
#endif // CONTENT_BROWSER_LOADER_DELEGATE_IMPL_H_
|