| Index: Source/core/workers/WorkerThread.h
|
| diff --git a/Source/core/workers/WorkerThread.h b/Source/core/workers/WorkerThread.h
|
| index 83bf3f445e41e95042e7eabd0af2408d8394f039..a58d1e7210f8386f38f266b3ee47b6a08cdb1191 100644
|
| --- a/Source/core/workers/WorkerThread.h
|
| +++ b/Source/core/workers/WorkerThread.h
|
| @@ -35,6 +35,10 @@
|
| #include "wtf/PassRefPtr.h"
|
| #include "wtf/RefCounted.h"
|
|
|
| +namespace blink {
|
| +class WebWaitableEvent;
|
| +}
|
| +
|
| namespace WebCore {
|
|
|
| class KURL;
|
| @@ -53,6 +57,10 @@ namespace WebCore {
|
| bool start();
|
| void stop();
|
|
|
| + // Can be used to wait for this worker thread to shut down.
|
| + // (This is signalled on the main thread, so it's assumed to be waited on the worker context thread)
|
| + blink::WebWaitableEvent* shutdownEvent() { return m_shutdownEvent.get(); }
|
| +
|
| bool isCurrentThread() const;
|
| WorkerRunLoop& runLoop() { return m_runLoop; }
|
| WorkerLoaderProxy& workerLoaderProxy() const { return m_workerLoaderProxy; }
|
| @@ -93,6 +101,9 @@ namespace WebCore {
|
| OwnPtr<WorkerThreadStartupData> m_startupData;
|
|
|
| NotificationClient* m_notificationClient;
|
| +
|
| + // Used to signal thread shutdown.
|
| + OwnPtr<blink::WebWaitableEvent> m_shutdownEvent;
|
| };
|
|
|
| } // namespace WebCore
|
|
|