OLD | NEW |
1 /* | 1 /* |
2 * This file is part of Adblock Plus <https://adblockplus.org/>, | 2 * This file is part of Adblock Plus <https://adblockplus.org/>, |
3 * Copyright (C) 2006-2015 Eyeo GmbH | 3 * Copyright (C) 2006-2015 Eyeo GmbH |
4 * | 4 * |
5 * Adblock Plus is free software: you can redistribute it and/or modify | 5 * Adblock Plus is free software: you can redistribute it and/or modify |
6 * it under the terms of the GNU General Public License version 3 as | 6 * it under the terms of the GNU General Public License version 3 as |
7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
8 * | 8 * |
9 * Adblock Plus is distributed in the hope that it will be useful, | 9 * Adblock Plus is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 12 matching lines...) Expand all Loading... |
23 #include <stdint.h> | 23 #include <stdint.h> |
24 #include <string> | 24 #include <string> |
25 #include <AdblockPlus/AppInfo.h> | 25 #include <AdblockPlus/AppInfo.h> |
26 #include <AdblockPlus/tr1_functional.h> | 26 #include <AdblockPlus/tr1_functional.h> |
27 #include <AdblockPlus/LogSystem.h> | 27 #include <AdblockPlus/LogSystem.h> |
28 #include <AdblockPlus/FileSystem.h> | 28 #include <AdblockPlus/FileSystem.h> |
29 #include <AdblockPlus/JsValue.h> | 29 #include <AdblockPlus/JsValue.h> |
30 #include <AdblockPlus/WebRequest.h> | 30 #include <AdblockPlus/WebRequest.h> |
31 | 31 |
32 #include "tr1_memory.h" | 32 #include "tr1_memory.h" |
33 #include "V8ValueHolder.h" | |
34 | 33 |
35 namespace v8 | 34 namespace v8 |
36 { | 35 { |
37 class Arguments; | 36 class Arguments; |
38 class Isolate; | 37 class Isolate; |
39 class Value; | 38 class Value; |
40 class Context; | 39 class Context; |
41 template<class T> class Handle; | 40 template<class T> class Handle; |
42 typedef Handle<Value>(*InvocationCallback)(const Arguments &args); | 41 typedef Handle<Value>(*InvocationCallback)(const Arguments &args); |
43 } | 42 } |
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 * instance by default, which might be sufficient. | 223 * instance by default, which might be sufficient. |
225 * @param The `LogSystem` instance to use. | 224 * @param The `LogSystem` instance to use. |
226 */ | 225 */ |
227 void SetLogSystem(LogSystemPtr val); | 226 void SetLogSystem(LogSystemPtr val); |
228 | 227 |
229 private: | 228 private: |
230 JsEngine(); | 229 JsEngine(); |
231 FileSystemPtr fileSystem; | 230 FileSystemPtr fileSystem; |
232 WebRequestPtr webRequest; | 231 WebRequestPtr webRequest; |
233 LogSystemPtr logSystem; | 232 LogSystemPtr logSystem; |
234 V8ValueHolder<v8::Context> context; | 233 std::unique_ptr<v8::Persistent<v8::Context>> context; |
235 EventMap eventCallbacks; | 234 EventMap eventCallbacks; |
236 }; | 235 }; |
237 } | 236 } |
238 | 237 |
239 #endif | 238 #endif |
OLD | NEW |