Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(276)

Unified Diff: content/browser/loader/throttling_resource_handler.h

Issue 2535723005: Stop using ResourceController in ResourceThrottle (Closed)
Patch Set: Addressed #62 Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/loader/throttling_resource_handler.h
diff --git a/content/browser/loader/throttling_resource_handler.h b/content/browser/loader/throttling_resource_handler.h
index 434151506ad250837132b7824b8bd5b704f7f59b..b44cde32bfeb755cc86eda43b6fac83fab2a74c6 100644
--- a/content/browser/loader/throttling_resource_handler.h
+++ b/content/browser/loader/throttling_resource_handler.h
@@ -10,7 +10,7 @@
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_vector.h"
#include "content/browser/loader/layered_resource_handler.h"
-#include "content/public/browser/resource_controller.h"
+#include "content/public/browser/resource_throttle.h"
#include "net/url_request/redirect_info.h"
#include "url/gurl.h"
@@ -20,12 +20,11 @@ class URLRequest;
namespace content {
-class ResourceThrottle;
struct ResourceResponse;
// Used to apply a list of ResourceThrottle instances to an URLRequest.
class ThrottlingResourceHandler : public LayeredResourceHandler,
- public ResourceController {
+ public ResourceThrottle::Delegate {
public:
// Takes ownership of the ResourceThrottle instances.
ThrottlingResourceHandler(std::unique_ptr<ResourceHandler> next_handler,
@@ -40,7 +39,7 @@ class ThrottlingResourceHandler : public LayeredResourceHandler,
bool OnResponseStarted(ResourceResponse* response, bool* defer) override;
bool OnWillStart(const GURL& url, bool* defer) override;
- // ResourceController implementation:
+ // ResourceThrottle::Delegate implementation:
void Cancel() override;
void CancelAndIgnore() override;
void CancelWithError(int error_code) override;
@@ -53,7 +52,7 @@ class ThrottlingResourceHandler : public LayeredResourceHandler,
// Called when the throttle at |throttle_index| defers a request. Logs the
// name of the throttle that delayed the request.
- void OnRequestDefered(int throttle_index);
+ void OnRequestDeferred(int throttle_index);
enum DeferredStage {
DEFERRED_NONE,
« no previous file with comments | « content/browser/loader/resource_scheduler_unittest.cc ('k') | content/browser/loader/throttling_resource_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698