Chromium Code Reviews| Index: chrome/browser/prerender/prerender_resource_throttle.h |
| diff --git a/chrome/browser/prerender/prerender_resource_throttle.h b/chrome/browser/prerender/prerender_resource_throttle.h |
| index a9f853ec9ccb45379d74940b614b10688629d6d5..a9fa3e039beb770dd115ea8a5c5227f08aa9ce2e 100644 |
| --- a/chrome/browser/prerender/prerender_resource_throttle.h |
| +++ b/chrome/browser/prerender/prerender_resource_throttle.h |
| @@ -14,6 +14,7 @@ |
| #include "content/public/browser/resource_request_info.h" |
| #include "content/public/browser/resource_throttle.h" |
| #include "content/public/common/resource_type.h" |
| +#include "net/base/request_priority.h" |
| class GURL; |
| @@ -50,6 +51,9 @@ class PrerenderResourceThrottle |
| // May only be called if currently throttling the resource. |
| void ResumeHandler(); |
| + // Resets the resource priority back to its original value. |
| + void ResetResourcePriority(); |
| + |
| static void OverridePrerenderContentsForTesting(PrerenderContents* contents); |
| private: |
| @@ -89,6 +93,10 @@ class PrerenderResourceThrottle |
| net::URLRequest* request_; |
| int load_flags_; // Load flags to be OR'ed with the existing request flags. |
|
Charlie Harrison
2017/04/12 12:37:26
nit: newline below.
droger
2017/04/12 13:20:54
Done.
|
| + // The throttle changes most request priorities to IDLE during prerendering. |
| + // The priority is reset back to the original priority when prerendering is |
| + // finished, unless the original priority is IDLE. |
| + net::RequestPriority original_request_priority_; |
| scoped_refptr<PrerenderThrottleInfo> prerender_throttle_info_; |