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

Unified Diff: include/AdblockPlus/JsEngine.h

Issue 9846017: Make JavaScript sources compile into the library; convert JavaScript files on the fly (Closed)
Patch Set: Review comments addressed Created March 15, 2013, 3:59 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 | « convert_js.py ('k') | lib/adblockplus.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/AdblockPlus/JsEngine.h
===================================================================
--- a/include/AdblockPlus/JsEngine.h
+++ b/include/AdblockPlus/JsEngine.h
@@ -16,17 +16,19 @@ namespace AdblockPlus
JsError(const v8::Handle<v8::Value> exception);
};
class JsEngine
{
public:
JsEngine(const FileReader* const fileReader,
ErrorCallback* const errorCallback);
- void Evaluate(const std::string& source);
+ void Evaluate(const char* source, const char* filename = NULL);
+ void Evaluate(const std::string& source,
+ const std::string& filename = "");
void Load(const std::string& scriptPath);
std::string Call(const std::string& functionName);
void Gc();
private:
const FileReader* const fileReader;
v8::Persistent<v8::Context> context;
};
« no previous file with comments | « convert_js.py ('k') | lib/adblockplus.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld