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

Unified Diff: third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.h

Issue 2270693002: WebSocket: Consolidate inter-thread synchronous function calls (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address review comment Created 4 years, 4 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 | « no previous file | third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.h
diff --git a/third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.h b/third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.h
index c33f5ac0f167b97c6bc46c7e590295886a17e558..5274c4c6599493c2dd24921c301a8afcf50ff15b 100644
--- a/third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.h
+++ b/third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.h
@@ -95,7 +95,7 @@ public:
// SourceLocation parameter may be shown when the connection fails.
bool initialize(std::unique_ptr<SourceLocation>, ExecutionContext*);
- void connect(const KURL&, const String& protocol);
+ bool connect(const KURL&, const String& protocol);
void sendTextAsCharVector(std::unique_ptr<Vector<char>>);
void sendBinaryAsCharVector(std::unique_ptr<Vector<char>>);
void sendBlob(PassRefPtr<BlobDataHandle>);
@@ -132,9 +132,10 @@ public:
public:
Bridge(WebSocketChannelClient*, WorkerGlobalScope&);
~Bridge();
+
// SourceLocation parameter may be shown when the connection fails.
- void initialize(std::unique_ptr<SourceLocation>);
- bool connect(const KURL&, const String& protocol);
+ bool connect(std::unique_ptr<SourceLocation>, const KURL&, const String& protocol);
+
void send(const CString& message);
void send(const DOMArrayBuffer&, unsigned byteOffset, unsigned byteLength);
void send(PassRefPtr<BlobDataHandle>);
@@ -142,7 +143,7 @@ public:
void fail(const String& reason, MessageLevel, std::unique_ptr<SourceLocation>);
void disconnect();
- void createPeerOnMainThread(std::unique_ptr<SourceLocation>, WorkerThreadLifecycleContext*, ExecutionContext*);
+ void connectOnMainThread(std::unique_ptr<SourceLocation>, WorkerThreadLifecycleContext*, const KURL&, const String& protocol, ExecutionContext*);
// Returns null when |disconnect| has already been called.
WebSocketChannelClient* client() { return m_client; }
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/websockets/WorkerWebSocketChannel.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698