| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading | 5 // See http://dev.chromium.org/developers/design-documents/multi-process-resourc
e-loading |
| 6 | 6 |
| 7 #include "content/child/resource_dispatcher.h" | 7 #include "content/child/resource_dispatcher.h" |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 | 66 |
| 67 // ResourceLoaderBridge implementation ---------------------------------------- | 67 // ResourceLoaderBridge implementation ---------------------------------------- |
| 68 | 68 |
| 69 class IPCResourceLoaderBridge : public ResourceLoaderBridge { | 69 class IPCResourceLoaderBridge : public ResourceLoaderBridge { |
| 70 public: | 70 public: |
| 71 IPCResourceLoaderBridge(ResourceDispatcher* dispatcher, | 71 IPCResourceLoaderBridge(ResourceDispatcher* dispatcher, |
| 72 const RequestInfo& request_info); | 72 const RequestInfo& request_info); |
| 73 virtual ~IPCResourceLoaderBridge(); | 73 virtual ~IPCResourceLoaderBridge(); |
| 74 | 74 |
| 75 // ResourceLoaderBridge | 75 // ResourceLoaderBridge |
| 76 virtual void SetRequestBody(ResourceRequestBody* request_body) OVERRIDE; | 76 virtual void SetRequestBody(ResourceRequestBody* request_body) override; |
| 77 virtual bool Start(RequestPeer* peer) OVERRIDE; | 77 virtual bool Start(RequestPeer* peer) override; |
| 78 virtual void Cancel() OVERRIDE; | 78 virtual void Cancel() override; |
| 79 virtual void SetDefersLoading(bool value) OVERRIDE; | 79 virtual void SetDefersLoading(bool value) override; |
| 80 virtual void DidChangePriority(net::RequestPriority new_priority, | 80 virtual void DidChangePriority(net::RequestPriority new_priority, |
| 81 int intra_priority_value) OVERRIDE; | 81 int intra_priority_value) override; |
| 82 virtual bool AttachThreadedDataReceiver( | 82 virtual bool AttachThreadedDataReceiver( |
| 83 blink::WebThreadedDataReceiver* threaded_data_receiver) OVERRIDE; | 83 blink::WebThreadedDataReceiver* threaded_data_receiver) override; |
| 84 virtual void SyncLoad(SyncLoadResponse* response) OVERRIDE; | 84 virtual void SyncLoad(SyncLoadResponse* response) override; |
| 85 | 85 |
| 86 private: | 86 private: |
| 87 // The resource dispatcher for this loader. The bridge doesn't own it, but | 87 // The resource dispatcher for this loader. The bridge doesn't own it, but |
| 88 // it's guaranteed to outlive the bridge. | 88 // it's guaranteed to outlive the bridge. |
| 89 ResourceDispatcher* dispatcher_; | 89 ResourceDispatcher* dispatcher_; |
| 90 | 90 |
| 91 // The request to send, created on initialization for modification and | 91 // The request to send, created on initialization for modification and |
| 92 // appending data. | 92 // appending data. |
| 93 ResourceHostMsg_Request request_; | 93 ResourceHostMsg_Request request_; |
| 94 | 94 |
| (...skipping 790 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 885 void ResourceDispatcher::ReleaseResourcesInMessageQueue(MessageQueue* queue) { | 885 void ResourceDispatcher::ReleaseResourcesInMessageQueue(MessageQueue* queue) { |
| 886 while (!queue->empty()) { | 886 while (!queue->empty()) { |
| 887 IPC::Message* message = queue->front(); | 887 IPC::Message* message = queue->front(); |
| 888 ReleaseResourcesInDataMessage(*message); | 888 ReleaseResourcesInDataMessage(*message); |
| 889 queue->pop_front(); | 889 queue->pop_front(); |
| 890 delete message; | 890 delete message; |
| 891 } | 891 } |
| 892 } | 892 } |
| 893 | 893 |
| 894 } // namespace content | 894 } // namespace content |
| OLD | NEW |