summaryrefslogtreecommitdiffstats
path: root/net/url_request/url_request.h
diff options
context:
space:
mode:
authormpcomplete@chromium.org <mpcomplete@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-10 22:28:21 +0000
committermpcomplete@chromium.org <mpcomplete@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-08-10 22:28:21 +0000
commit9c235f046d073692051cafefac55e7f55eef4083 (patch)
tree29c34af7d1c9a5e280a1df3a04bd14d29ff47980 /net/url_request/url_request.h
parenta3c400b9284179e1d846861d2494e2eaeddc6a48 (diff)
downloadchromium_src-9c235f046d073692051cafefac55e7f55eef4083.zip
chromium_src-9c235f046d073692051cafefac55e7f55eef4083.tar.gz
chromium_src-9c235f046d073692051cafefac55e7f55eef4083.tar.bz2
Add a status message "Waiting for extension Foo..." when there's a request
blocked on an extension with a webrequest API event handler. BUG=82618 TEST=no Review URL: http://codereview.chromium.org/7523042 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@96226 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/url_request/url_request.h')
-rw-r--r--net/url_request/url_request.h22
1 files changed, 20 insertions, 2 deletions
diff --git a/net/url_request/url_request.h b/net/url_request/url_request.h
index f6d5371..c5354e1 100644
--- a/net/url_request/url_request.h
+++ b/net/url_request/url_request.h
@@ -431,8 +431,13 @@ class NET_API URLRequest : NON_EXPORTED_BASE(public base::NonThreadSafe) {
return extra_request_headers_;
}
- // Returns the current load state for the request.
- LoadState GetLoadState() const;
+ // Returns the current load state for the request. |param| is an optional
+ // parameter describing details related to the load state. Not all load states
+ // have a parameter.
+ LoadStateWithParam GetLoadState() const;
+ void SetLoadStateParam(const string16& param) {
+ load_state_param_ = param;
+ }
// Returns the current upload progress in bytes.
uint64 GetUploadProgress() const;
@@ -715,6 +720,11 @@ class NET_API URLRequest : NON_EXPORTED_BASE(public base::NonThreadSafe) {
CookieOptions* options) const;
void NotifyReadCompleted(int bytes_read);
+ // Called when the delegate blocks or unblocks this request when intercepting
+ // certain requests.
+ void SetBlockedOnDelegate();
+ void SetUnblockedOnDelegate();
+
// Contextual information used for this request (can be NULL). This contains
// most of the dependencies which are shared between requests (disk cache,
// cookie store, socket pool, etc.)
@@ -775,6 +785,14 @@ class NET_API URLRequest : NON_EXPORTED_BASE(public base::NonThreadSafe) {
// A globally unique identifier for this request.
const uint64 identifier_;
+ // True if this request is blocked waiting for the network delegate to resume
+ // it.
+ bool blocked_on_delegate_;
+
+ // An optional parameter that provides additional information about the load
+ // state. Only used with the LOAD_STATE_WAITING_FOR_DELEGATE state.
+ string16 load_state_param_;
+
base::debug::LeakTracker<URLRequest> leak_tracker_;
// Callback passed to the network delegate to notify us when a blocked request