Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/JsEngine.cpp

Issue 10862008: Automatically add default filter subscription when necessary. (Closed)
Patch Set: Created May 27, 2013, 2:12 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/GlobalJsObject.cpp ('k') | test/AppInfoJsObject.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/JsEngine.cpp
===================================================================
--- a/src/JsEngine.cpp
+++ b/src/JsEngine.cpp
@@ -79,21 +79,21 @@ void AdblockPlus::JsEngine::SetEventCall
eventCallbacks[eventName] = callback;
}
void AdblockPlus::JsEngine::RemoveEventCallback(const std::string& eventName)
{
eventCallbacks.erase(eventName);
}
-void AdblockPlus::JsEngine::TriggerEvent(const std::string& eventName)
+void AdblockPlus::JsEngine::TriggerEvent(const std::string& eventName, AdblockPlus::JsValueList& params)
{
EventMap::iterator it = eventCallbacks.find(eventName);
if (it != eventCallbacks.end())
- it->second();
+ it->second(params);
}
void AdblockPlus::JsEngine::Gc()
{
while (!v8::V8::IdleNotification());
}
AdblockPlus::JsValuePtr AdblockPlus::JsEngine::NewValue(const std::string& val)
« no previous file with comments | « src/GlobalJsObject.cpp ('k') | test/AppInfoJsObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld