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

Unified Diff: Source/modules/websockets/WorkerThreadableWebSocketChannel.h

Issue 17648006: Rename WorkerContext to WorkerGlobalScope (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase on master Created 7 years, 6 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
Index: Source/modules/websockets/WorkerThreadableWebSocketChannel.h
diff --git a/Source/modules/websockets/WorkerThreadableWebSocketChannel.h b/Source/modules/websockets/WorkerThreadableWebSocketChannel.h
index f60811064f154554c59d8f5a89a66d9c53047978..9a40638222a31ea159ed21aff7e06cfae231497f 100644
--- a/Source/modules/websockets/WorkerThreadableWebSocketChannel.h
+++ b/Source/modules/websockets/WorkerThreadableWebSocketChannel.h
@@ -32,7 +32,7 @@
#define WorkerThreadableWebSocketChannel_h
#include "core/page/ConsoleTypes.h"
-#include "core/workers/WorkerContext.h"
+#include "core/workers/WorkerGlobalScope.h"
#include "modules/websockets/WebSocketChannel.h"
#include "modules/websockets/WebSocketChannelClient.h"
@@ -49,16 +49,16 @@ namespace WebCore {
class KURL;
class ScriptExecutionContext;
class ThreadableWebSocketChannelClientWrapper;
-class WorkerContext;
+class WorkerGlobalScope;
class WorkerLoaderProxy;
class WorkerRunLoop;
class WorkerThreadableWebSocketChannel : public RefCounted<WorkerThreadableWebSocketChannel>, public WebSocketChannel {
WTF_MAKE_FAST_ALLOCATED;
public:
- static PassRefPtr<WebSocketChannel> create(WorkerContext* workerContext, WebSocketChannelClient* client, const String& taskMode)
+ static PassRefPtr<WebSocketChannel> create(WorkerGlobalScope* workerGlobalScope, WebSocketChannelClient* client, const String& taskMode)
{
- return adoptRef(new WorkerThreadableWebSocketChannel(workerContext, client, taskMode));
+ return adoptRef(new WorkerThreadableWebSocketChannel(workerGlobalScope, client, taskMode));
}
virtual ~WorkerThreadableWebSocketChannel();
@@ -130,9 +130,9 @@ private:
// Bridge for Peer. Running on the worker thread.
class Bridge : public RefCounted<Bridge> {
public:
- static PassRefPtr<Bridge> create(PassRefPtr<ThreadableWebSocketChannelClientWrapper> workerClientWrapper, PassRefPtr<WorkerContext> workerContext, const String& taskMode)
+ static PassRefPtr<Bridge> create(PassRefPtr<ThreadableWebSocketChannelClientWrapper> workerClientWrapper, PassRefPtr<WorkerGlobalScope> workerGlobalScope, const String& taskMode)
{
- return adoptRef(new Bridge(workerClientWrapper, workerContext, taskMode));
+ return adoptRef(new Bridge(workerClientWrapper, workerGlobalScope, taskMode));
}
~Bridge();
// sourceURLAtConnection and lineNumberAtConnection parameters may
@@ -153,7 +153,7 @@ private:
using RefCounted<Bridge>::deref;
private:
- Bridge(PassRefPtr<ThreadableWebSocketChannelClientWrapper>, PassRefPtr<WorkerContext>, const String& taskMode);
+ Bridge(PassRefPtr<ThreadableWebSocketChannelClientWrapper>, PassRefPtr<WorkerGlobalScope>, const String& taskMode);
static void setWebSocketChannel(ScriptExecutionContext*, Bridge* thisPtr, Peer*, PassRefPtr<ThreadableWebSocketChannelClientWrapper>);
@@ -170,13 +170,13 @@ private:
void waitForMethodCompletion();
RefPtr<ThreadableWebSocketChannelClientWrapper> m_workerClientWrapper;
- RefPtr<WorkerContext> m_workerContext;
+ RefPtr<WorkerGlobalScope> m_workerGlobalScope;
WorkerLoaderProxy& m_loaderProxy;
String m_taskMode;
Peer* m_peer;
};
- WorkerThreadableWebSocketChannel(WorkerContext*, WebSocketChannelClient*, const String& taskMode);
+ WorkerThreadableWebSocketChannel(WorkerGlobalScope*, WebSocketChannelClient*, const String& taskMode);
static void mainThreadConnect(ScriptExecutionContext*, Peer*, const KURL&, const String& protocol);
static void mainThreadSend(ScriptExecutionContext*, Peer*, const String& message);
@@ -189,9 +189,9 @@ private:
static void mainThreadSuspend(ScriptExecutionContext*, Peer*);
static void mainThreadResume(ScriptExecutionContext*, Peer*);
- class WorkerContextDidInitializeTask;
+ class WorkerGlobalScopeDidInitializeTask;
- RefPtr<WorkerContext> m_workerContext;
+ RefPtr<WorkerGlobalScope> m_workerGlobalScope;
RefPtr<ThreadableWebSocketChannelClientWrapper> m_workerClientWrapper;
RefPtr<Bridge> m_bridge;
String m_sourceURLAtConnection;
« no previous file with comments | « Source/modules/websockets/WorkerContextWebSocket.idl ('k') | Source/modules/websockets/WorkerThreadableWebSocketChannel.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698