| Index: third_party/WebKit/Source/core/workers/InProcessWorkerMessagingProxy.h
|
| diff --git a/third_party/WebKit/Source/core/workers/InProcessWorkerMessagingProxy.h b/third_party/WebKit/Source/core/workers/InProcessWorkerMessagingProxy.h
|
| index f1aa6e3c6e5f6254446fe494fe01baffb0ad3f84..553e0d8c43a53534fc5bd4ad37cca9ab78a779bb 100644
|
| --- a/third_party/WebKit/Source/core/workers/InProcessWorkerMessagingProxy.h
|
| +++ b/third_party/WebKit/Source/core/workers/InProcessWorkerMessagingProxy.h
|
| @@ -70,9 +70,12 @@ public:
|
| void reportException(const String& errorMessage, std::unique_ptr<SourceLocation>, int exceptionId);
|
| void reportConsoleMessage(MessageSource, MessageLevel, const String& message, std::unique_ptr<SourceLocation>);
|
| void postMessageToPageInspector(const String&);
|
| - void confirmMessageFromWorkerObject(bool hasPendingActivity);
|
| - void reportPendingActivity(bool hasPendingActivity);
|
| - void workerThreadTerminated();
|
| +
|
| + // 'virtual' for testing.
|
| + virtual void confirmMessageFromWorkerObject();
|
| + virtual void pendingActivityFinished();
|
| + virtual void workerThreadTerminated();
|
| +
|
| void workerThreadCreated();
|
|
|
| ExecutionContext* getExecutionContext() const { return m_executionContext.get(); }
|
| @@ -90,6 +93,9 @@ protected:
|
| InProcessWorkerObjectProxy& workerObjectProxy() { return *m_workerObjectProxy.get(); }
|
|
|
| private:
|
| + friend class InProcessWorkerMessagingProxyForTest;
|
| + InProcessWorkerMessagingProxy(ExecutionContext*, InProcessWorkerBase*, WorkerClients*);
|
| +
|
| void workerObjectDestroyedInternal();
|
|
|
| // WorkerLoaderProxyProvider
|
| @@ -110,10 +116,7 @@ private:
|
| // Unconfirmed messages from the parent context thread to the worker thread.
|
| unsigned m_unconfirmedMessageCount;
|
|
|
| - // The latest confirmation from worker thread reported that it was still
|
| - // active.
|
| - bool m_workerThreadHadPendingActivity;
|
| -
|
| + bool m_workerGlobalScopeMayHavePendingActivity;
|
| bool m_askedToTerminate;
|
|
|
| // Tasks are queued here until there's a thread object created.
|
|
|