Index: chrome/browser/net/chrome_network_delegate.h |
diff --git a/chrome/browser/net/chrome_network_delegate.h b/chrome/browser/net/chrome_network_delegate.h |
index fbac0360cd5fb605db7cc3498a856c9c4fb7ba18..5b3fb1576fd90c4330d72a7a91edc3cebc9452aa 100644 |
--- a/chrome/browser/net/chrome_network_delegate.h |
+++ b/chrome/browser/net/chrome_network_delegate.h |
@@ -7,17 +7,22 @@ |
#pragma once |
#include "base/basictypes.h" |
+#include "base/ref_counted.h" |
+#include "chrome/browser/profiles/profile.h" |
#include "net/base/network_delegate.h" |
-class ExtensionIOEventRouter; |
+class ExtensionEventRouterForwarder; |
// ChromeNetworkDelegate is the central point from within the chrome code to |
// add hooks into the network stack. |
class ChromeNetworkDelegate : public net::NetworkDelegate { |
public: |
+ // If |profile| is NULL, events will be broadcasted to all profiles, |
+ // otherwise, they will be only send to the specified profile. |
explicit ChromeNetworkDelegate( |
- ExtensionIOEventRouter* extension_io_event_router); |
- ~ChromeNetworkDelegate(); |
+ ExtensionEventRouterForwarder* event_router, |
+ ProfileId profile_id); |
+ virtual ~ChromeNetworkDelegate(); |
private: |
// NetworkDelegate methods: |
@@ -26,7 +31,8 @@ class ChromeNetworkDelegate : public net::NetworkDelegate { |
virtual void OnResponseStarted(net::URLRequest* request); |
virtual void OnReadCompleted(net::URLRequest* request, int bytes_read); |
- ExtensionIOEventRouter* const extension_io_event_router_; |
+ scoped_refptr<ExtensionEventRouterForwarder> event_router_; |
+ const ProfileId profile_id_; |
DISALLOW_COPY_AND_ASSIGN(ChromeNetworkDelegate); |
}; |