Chromium Code Reviews| Index: content/child/resource_dispatcher.h |
| diff --git a/content/child/resource_dispatcher.h b/content/child/resource_dispatcher.h |
| index 7f7911e71e35660c57cbf7c74b508359cd076a04..8eef33774d4f4ea98161e4b4ca0c7e18dfe3dc5b 100644 |
| --- a/content/child/resource_dispatcher.h |
| +++ b/content/child/resource_dispatcher.h |
| @@ -31,9 +31,11 @@ struct ResourceResponseInfo; |
| namespace content { |
| class RequestPeer; |
| class ResourceDispatcherDelegate; |
| +class ResourceRequestBody; |
| struct RequestInfo; |
| struct ResourceResponseHead; |
| struct SiteIsolationResponseMetaData; |
| +struct SyncLoadResponse; |
| // This class serves as a communication interface between the |
| // ResourceDispatcherHost in the browser process and the ResourceLoaderBridge in |
| @@ -46,11 +48,13 @@ class CONTENT_EXPORT ResourceDispatcher : public IPC::Listener { |
| // IPC::Listener implementation. |
| virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; |
| - // Creates a ResourceLoaderBridge for this type of dispatcher, this is so |
| - // this can be tested regardless of the ResourceLoaderBridge::Create |
| - // implementation. |
| - webkit_glue::ResourceLoaderBridge* CreateBridge( |
| - const RequestInfo& request_info); |
| + void CreateBridge(const RequestInfo& request_info); |
| + void SetRequestBody(ResourceRequestBody* request_body); |
| + bool Start(RequestPeer* peer); |
| + void Cancel(); |
| + void SetDefersLoading(bool value); |
| + void DidChangePriority(net::RequestPriority new_priority); |
| + void SyncLoad(SyncLoadResponse* response); |
| // Adds a request from the pending_requests_ list, returning the new |
| // requests' ID |
| @@ -91,6 +95,7 @@ class CONTENT_EXPORT ResourceDispatcher : public IPC::Listener { |
| private: |
| friend class ResourceDispatcherTest; |
| + class IPCResourceLoaderBridge; |
|
tfarina
2014/04/05 02:03:46
John, I burned my head, and this was the way I fou
jam
2014/04/07 16:43:22
you can forward declare that struct and put it int
tfarina
2014/04/11 01:43:55
Done.
|
| typedef std::deque<IPC::Message*> MessageQueue; |
| struct PendingRequestInfo { |
| @@ -212,6 +217,8 @@ class CONTENT_EXPORT ResourceDispatcher : public IPC::Listener { |
| // IO thread timestamp for ongoing IPC message. |
| base::TimeTicks io_timestamp_; |
| + scoped_ptr<IPCResourceLoaderBridge> bridge_; |
| + |
| DISALLOW_COPY_AND_ASSIGN(ResourceDispatcher); |
| }; |