| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "modules/compositorworker/CompositorWorkerThread.h" | 5 #include "modules/compositorworker/CompositorWorkerThread.h" |
| 6 | 6 |
| 7 #include "bindings/core/v8/ScriptSourceCode.h" | 7 #include "bindings/core/v8/ScriptSourceCode.h" |
| 8 #include "bindings/core/v8/V8GCController.h" | 8 #include "bindings/core/v8/V8GCController.h" |
| 9 #include "core/inspector/ConsoleMessage.h" | 9 #include "core/inspector/ConsoleMessage.h" |
| 10 #include "core/testing/DummyPageHolder.h" | 10 #include "core/testing/DummyPageHolder.h" |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 void reportConsoleMessage(PassRefPtrWillBeRawPtr<ConsoleMessage>) override {
} | 79 void reportConsoleMessage(PassRefPtrWillBeRawPtr<ConsoleMessage>) override {
} |
| 80 void postMessageToPageInspector(const String&) override {} | 80 void postMessageToPageInspector(const String&) override {} |
| 81 void postWorkerConsoleAgentEnabled() override {} | 81 void postWorkerConsoleAgentEnabled() override {} |
| 82 | 82 |
| 83 void didEvaluateWorkerScript(bool success) override {} | 83 void didEvaluateWorkerScript(bool success) override {} |
| 84 void workerGlobalScopeStarted(WorkerGlobalScope*) override {} | 84 void workerGlobalScopeStarted(WorkerGlobalScope*) override {} |
| 85 void workerGlobalScopeClosed() override {} | 85 void workerGlobalScopeClosed() override {} |
| 86 void workerThreadTerminated() override {} | 86 void workerThreadTerminated() override {} |
| 87 void willDestroyWorkerGlobalScope() override {} | 87 void willDestroyWorkerGlobalScope() override {} |
| 88 | 88 |
| 89 ExecutionContext* executionContext() override { return m_executionContext.ge
t(); } | 89 ExecutionContext* getExecutionContext() override { return m_executionContext
.get(); } |
| 90 | 90 |
| 91 private: | 91 private: |
| 92 TestCompositorWorkerObjectProxy(ExecutionContext* context) | 92 TestCompositorWorkerObjectProxy(ExecutionContext* context) |
| 93 : WorkerObjectProxy(nullptr) | 93 : WorkerObjectProxy(nullptr) |
| 94 , m_executionContext(context) | 94 , m_executionContext(context) |
| 95 { | 95 { |
| 96 } | 96 } |
| 97 | 97 |
| 98 RefPtrWillBePersistent<ExecutionContext> m_executionContext; | 98 RefPtrWillBePersistent<ExecutionContext> m_executionContext; |
| 99 }; | 99 }; |
| (...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 296 v8::Isolate* secondIsolate = secondWorker->isolate(); | 296 v8::Isolate* secondIsolate = secondWorker->isolate(); |
| 297 ASSERT(secondIsolate); | 297 ASSERT(secondIsolate); |
| 298 EXPECT_EQ(firstIsolate, secondIsolate); | 298 EXPECT_EQ(firstIsolate, secondIsolate); |
| 299 | 299 |
| 300 // Verify that the isolate can run some scripts correctly in the second work
er. | 300 // Verify that the isolate can run some scripts correctly in the second work
er. |
| 301 checkWorkerCanExecuteScript(secondWorker.get()); | 301 checkWorkerCanExecuteScript(secondWorker.get()); |
| 302 secondWorker->terminateAndWait(); | 302 secondWorker->terminateAndWait(); |
| 303 } | 303 } |
| 304 | 304 |
| 305 } // namespace blink | 305 } // namespace blink |
| OLD | NEW |