Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(63)

Unified Diff: extensions/renderer/dispatcher.cc

Issue 2940893002: [Extensions] Pass EventFilteringInfo directly in DispatchEvent message (Closed)
Patch Set: . Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « extensions/renderer/dispatcher.h ('k') | extensions/renderer/event_bindings.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/renderer/dispatcher.cc
diff --git a/extensions/renderer/dispatcher.cc b/extensions/renderer/dispatcher.cc
index 4930eb69ec9f7682104a71f0a18d38089610643e..224946c63ba79d55ed664ddbd8161c49004bb7bc 100644
--- a/extensions/renderer/dispatcher.cc
+++ b/extensions/renderer/dispatcher.cc
@@ -661,11 +661,10 @@ void Dispatcher::OnExtensionResponse(int request_id,
bindings_system_->HandleResponse(request_id, success, response, error);
}
-void Dispatcher::DispatchEvent(
- const std::string& extension_id,
- const std::string& event_name,
- const base::ListValue& event_args,
- const base::DictionaryValue& filtering_info) const {
+void Dispatcher::DispatchEvent(const std::string& extension_id,
+ const std::string& event_name,
+ const base::ListValue& event_args,
+ const EventFilteringInfo& filtering_info) const {
script_context_set_->ForEach(
extension_id, nullptr,
base::Bind(&ExtensionBindingsSystem::DispatchEventInContext,
@@ -1006,7 +1005,7 @@ void Dispatcher::OnActivateExtension(const std::string& extension_id) {
void Dispatcher::OnCancelSuspend(const std::string& extension_id) {
DispatchEvent(extension_id, kOnSuspendCanceledEvent, base::ListValue(),
- base::DictionaryValue());
+ EventFilteringInfo());
}
void Dispatcher::OnDeliverMessage(const PortId& target_port_id,
@@ -1155,7 +1154,7 @@ void Dispatcher::OnSuspend(const std::string& extension_id) {
// that it still considers the extension idle despite any activity the suspend
// event creates.
DispatchEvent(extension_id, kOnSuspendEvent, base::ListValue(),
- base::DictionaryValue());
+ EventFilteringInfo());
RenderThread::Get()->Send(new ExtensionHostMsg_SuspendAck(extension_id));
}
« no previous file with comments | « extensions/renderer/dispatcher.h ('k') | extensions/renderer/event_bindings.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698