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

Unified Diff: chrome/browser/extensions/event_router_forwarder.h

Issue 10694085: Refactor extension event distribution to use Values instead of JSON strings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing memory leak in a test. Created 8 years, 4 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 | « chrome/browser/extensions/event_router.cc ('k') | chrome/browser/extensions/event_router_forwarder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/event_router_forwarder.h
diff --git a/chrome/browser/extensions/event_router_forwarder.h b/chrome/browser/extensions/event_router_forwarder.h
index a0ed66c20b1a0d63dd1a6b08744e19daf3c6af9a..2752c8222ed58908678cf590c93b90b096e87954 100644
--- a/chrome/browser/extensions/event_router_forwarder.h
+++ b/chrome/browser/extensions/event_router_forwarder.h
@@ -9,6 +9,7 @@
#include "base/basictypes.h"
#include "base/memory/ref_counted.h"
+#include "base/values.h"
#include "chrome/browser/profiles/profile.h"
#include "content/public/browser/browser_thread.h"
@@ -35,7 +36,7 @@ class EventRouterForwarder
// on all (original) profiles' EventRouters.
// May be called on any thread.
void BroadcastEventToRenderers(const std::string& event_name,
- const std::string& event_args,
+ scoped_ptr<base::ListValue> event_args,
const GURL& event_url);
// Calls
@@ -45,7 +46,7 @@ class EventRouterForwarder
// May be called on any thread.
void BroadcastEventToExtension(const std::string& extension_id,
const std::string& event_name,
- const std::string& event_args,
+ scoped_ptr<base::ListValue> event_args,
const GURL& event_url);
// Calls
@@ -53,7 +54,7 @@ class EventRouterForwarder
// use_profile_to_restrict_events ? profile : NULL, event_url)
// on |profile|'s EventRouter. May be called on any thread.
void DispatchEventToRenderers(const std::string& event_name,
- const std::string& event_args,
+ scoped_ptr<base::ListValue> event_args,
void* profile,
bool use_profile_to_restrict_events,
const GURL& event_url);
@@ -64,7 +65,7 @@ class EventRouterForwarder
// on |profile|'s EventRouter. May be called on any thread.
void DispatchEventToExtension(const std::string& extension_id,
const std::string& event_name,
- const std::string& event_args,
+ scoped_ptr<base::ListValue> event_args,
void* profile,
bool use_profile_to_restrict_events,
const GURL& event_url);
@@ -77,7 +78,7 @@ class EventRouterForwarder
// Virtual for testing.
virtual void HandleEvent(const std::string& extension_id,
const std::string& event_name,
- const std::string& event_args,
+ scoped_ptr<base::ListValue> event_args,
void* profile,
bool use_profile_to_restrict_events,
const GURL& event_url);
@@ -89,7 +90,7 @@ class EventRouterForwarder
virtual void CallEventRouter(Profile* profile,
const std::string& extension_id,
const std::string& event_name,
- const std::string& event_args,
+ scoped_ptr<base::ListValue> event_args,
Profile* restrict_to_profile,
const GURL& event_url);
« no previous file with comments | « chrome/browser/extensions/event_router.cc ('k') | chrome/browser/extensions/event_router_forwarder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698