Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1423)

Unified Diff: Source/core/workers/WorkerThread.cpp

Issue 1140503003: workers: Change how debugger-tasks are posted to the thread. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: back-to-patchset2 Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/workers/WorkerThread.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/workers/WorkerThread.cpp
diff --git a/Source/core/workers/WorkerThread.cpp b/Source/core/workers/WorkerThread.cpp
index ae4d975ace85e8925837fa80135250ada250ba1d..b9b3521294d640f157956644edd2a14c49231976 100644
--- a/Source/core/workers/WorkerThread.cpp
+++ b/Source/core/workers/WorkerThread.cpp
@@ -249,24 +249,6 @@ private:
bool m_isInstrumented;
};
-class RunDebuggerQueueTask final : public ExecutionContextTask {
-public:
- static PassOwnPtr<RunDebuggerQueueTask> create(WorkerThread* thread)
- {
- return adoptPtr(new RunDebuggerQueueTask(thread));
- }
- virtual void performTask(ExecutionContext* context) override
- {
- ASSERT(context->isWorkerGlobalScope());
- m_thread->runDebuggerTask(WorkerThread::DontWaitForMessage);
- }
-
-private:
- explicit RunDebuggerQueueTask(WorkerThread* thread) : m_thread(thread) { }
-
- WorkerThread* m_thread;
-};
-
WorkerThread::WorkerThread(PassRefPtr<WorkerLoaderProxy> workerLoaderProxy, WorkerReportingProxy& workerReportingProxy)
: m_started(false)
, m_terminated(false)
@@ -561,10 +543,9 @@ void WorkerThread::terminateV8Execution()
v8::V8::TerminateExecution(m_isolate);
}
-void WorkerThread::postDebuggerTask(const WebTraceLocation& location, PassOwnPtr<ExecutionContextTask> task)
+void WorkerThread::appendDebuggerTask(PassOwnPtr<WebThread::Task> task)
{
- m_debuggerMessageQueue.append(WorkerThreadTask::create(*this, task, false));
- postTask(location, RunDebuggerQueueTask::create(this));
+ m_debuggerMessageQueue.append(task);
}
MessageQueueWaitResult WorkerThread::runDebuggerTask(WaitMode waitMode)
« no previous file with comments | « Source/core/workers/WorkerThread.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698