| Index: Source/core/workers/WorkerThread.h
|
| diff --git a/Source/core/workers/WorkerThread.h b/Source/core/workers/WorkerThread.h
|
| index d9bd49b952000d06cc50138b92223b7815c46e40..759b558fd4aee80e219e0fdf1bd0c5c3f1ab3731 100644
|
| --- a/Source/core/workers/WorkerThread.h
|
| +++ b/Source/core/workers/WorkerThread.h
|
| @@ -47,7 +47,6 @@ class WebWaitableEvent;
|
| class WorkerGlobalScope;
|
| class WorkerInspectorController;
|
| class WorkerReportingProxy;
|
| -class WorkerSharedTimer;
|
| class WorkerThreadShutdownFinishTask;
|
| class WorkerThreadStartupData;
|
| class WorkerThreadTask;
|
| @@ -122,8 +121,16 @@ protected:
|
| virtual void destroyIsolate();
|
| virtual void terminateV8Execution();
|
|
|
| + // This is protected virtual for testing.
|
| + virtual bool doIdleGc(double deadlineSeconds);
|
| +
|
| + WebThreadSupportingGC* threadForTesting() const
|
| + {
|
| + return m_thread.get();
|
| + }
|
| +
|
| private:
|
| - friend class WorkerSharedTimer;
|
| + friend class WorkerThreadIdleTask;
|
| friend class WorkerThreadShutdownFinishTask;
|
|
|
| void stopInShutdownSequence();
|
| @@ -131,7 +138,7 @@ private:
|
|
|
| void initialize();
|
| void cleanup();
|
| - void idleHandler();
|
| + void idleTask(double deadlineSeconds);
|
| void postDelayedTask(PassOwnPtr<ExecutionContextTask>, long long delayMs);
|
| void postDelayedTask(const WebTraceLocation&, PassOwnPtr<ExecutionContextTask>, long long delayMs);
|
|
|
| @@ -159,6 +166,8 @@ private:
|
| // Used to signal thread termination.
|
| OwnPtr<WebWaitableEvent> m_terminationEvent;
|
|
|
| + WebScheduler* m_webScheduler; // NOT OWNED.
|
| +
|
| // FIXME: This has to be last because of crbug.com/401397 - the
|
| // WorkerThread might get deleted before it had a chance to properly
|
| // shut down. By deleting the WebThread first, we can guarantee that
|
|
|