| 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-present eyeo GmbH | 3 * Copyright (C) 2006-present 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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 57   logSystem = creationParameters.logSystem ? std::move(creationParameters.logSys
     tem) : CreateDefaultLogSystem(); | 57   logSystem = creationParameters.logSystem ? std::move(creationParameters.logSys
     tem) : CreateDefaultLogSystem(); | 
| 58   timer = creationParameters.timer ? std::move(creationParameters.timer) : Creat
     eDefaultTimer(); | 58   timer = creationParameters.timer ? std::move(creationParameters.timer) : Creat
     eDefaultTimer(); | 
| 59   fileSystem = creationParameters.fileSystem ? std::move(creationParameters.file
     System) : CreateDefaultFileSystem(::DummyScheduler); | 59   fileSystem = creationParameters.fileSystem ? std::move(creationParameters.file
     System) : CreateDefaultFileSystem(::DummyScheduler); | 
| 60   webRequest = creationParameters.webRequest ? std::move(creationParameters.webR
     equest) : CreateDefaultWebRequest(::DummyScheduler); | 60   webRequest = creationParameters.webRequest ? std::move(creationParameters.webR
     equest) : CreateDefaultWebRequest(::DummyScheduler); | 
| 61 } | 61 } | 
| 62 | 62 | 
| 63 Platform::~Platform() | 63 Platform::~Platform() | 
| 64 { | 64 { | 
| 65 } | 65 } | 
| 66 | 66 | 
| 67 void Platform::SetUpJsEngine(const AppInfo& appInfo) | 67 void Platform::SetUpJsEngine(const AppInfo& appInfo, std::unique_ptr<IV8IsolateP
     rovider> isolate) | 
| 68 { | 68 { | 
| 69   std::lock_guard<std::mutex> lock(modulesMutex); | 69   std::lock_guard<std::mutex> lock(modulesMutex); | 
| 70   if (jsEngine) | 70   if (jsEngine) | 
| 71     return; | 71     return; | 
| 72   jsEngine = JsEngine::New(appInfo, *this); | 72   jsEngine = JsEngine::New(appInfo, *this, std::move(isolate)); | 
| 73 } | 73 } | 
| 74 | 74 | 
| 75 JsEngine& Platform::GetJsEngine() | 75 JsEngine& Platform::GetJsEngine() | 
| 76 { | 76 { | 
| 77   SetUpJsEngine(); | 77   SetUpJsEngine(); | 
| 78   return *jsEngine; | 78   return *jsEngine; | 
| 79 } | 79 } | 
| 80 | 80 | 
| 81 void Platform::CreateFilterEngineAsync(const FilterEngine::CreationParameters& p
     arameters, | 81 void Platform::CreateFilterEngineAsync(const FilterEngine::CreationParameters& p
     arameters, | 
| 82   const OnFilterEngineCreatedCallback& onCreated) | 82   const OnFilterEngineCreatedCallback& onCreated) | 
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 117 | 117 | 
| 118 IWebRequest& Platform::GetWebRequest() | 118 IWebRequest& Platform::GetWebRequest() | 
| 119 { | 119 { | 
| 120   return *webRequest; | 120   return *webRequest; | 
| 121 } | 121 } | 
| 122 | 122 | 
| 123 LogSystem& Platform::GetLogSystem() | 123 LogSystem& Platform::GetLogSystem() | 
| 124 { | 124 { | 
| 125   return *logSystem; | 125   return *logSystem; | 
| 126 } | 126 } | 
| OLD | NEW | 
|---|