OLD | NEW |
1 // Copyright (c) 2011 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 #include "chrome/browser/extensions/extension_event_router_forwarder.h" | 5 #include "chrome/browser/extensions/extension_event_router_forwarder.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "chrome/browser/browser_process.h" | 8 #include "chrome/browser/browser_process.h" |
9 #include "chrome/browser/extensions/extension_event_router.h" | 9 #include "chrome/browser/extensions/extension_event_router.h" |
10 #include "chrome/browser/profiles/profile_manager.h" | 10 #include "chrome/browser/profiles/profile_manager.h" |
11 #include "googleurl/src/gurl.h" | 11 #include "googleurl/src/gurl.h" |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
107 const GURL& event_url) { | 107 const GURL& event_url) { |
108 // We may not have an extension in cases like chromeos login | 108 // We may not have an extension in cases like chromeos login |
109 // (crosbug.com/12856), chrome_frame_net_tests.exe which reuses the chrome | 109 // (crosbug.com/12856), chrome_frame_net_tests.exe which reuses the chrome |
110 // browser single process framework. | 110 // browser single process framework. |
111 if (!profile->GetExtensionEventRouter()) | 111 if (!profile->GetExtensionEventRouter()) |
112 return; | 112 return; |
113 | 113 |
114 if (extension_id.empty()) { | 114 if (extension_id.empty()) { |
115 profile->GetExtensionEventRouter()-> | 115 profile->GetExtensionEventRouter()-> |
116 DispatchEventToRenderers( | 116 DispatchEventToRenderers( |
117 event_name, event_args, restrict_to_profile, event_url); | 117 event_name, event_args, restrict_to_profile, event_url, |
| 118 extensions::EventFilteringInfo()); |
118 } else { | 119 } else { |
119 profile->GetExtensionEventRouter()-> | 120 profile->GetExtensionEventRouter()-> |
120 DispatchEventToExtension( | 121 DispatchEventToExtension( |
121 extension_id, | 122 extension_id, |
122 event_name, event_args, restrict_to_profile, event_url); | 123 event_name, event_args, restrict_to_profile, event_url); |
123 } | 124 } |
124 } | 125 } |
OLD | NEW |