Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[Chromium] [WebSocket] Add WebSocket extensions query WebKit API
https://bugs.webkit.org/show_bug.cgi?id=80190

Reviewed by Darin Fisher.

* public/WebSocket.h: Add extensions() declaration.
(WebSocket):
* src/WebSocketImpl.cpp: Implement extensions() bridge.
(WebKit::WebSocketImpl::extensions):
(WebKit):
* src/WebSocketImpl.h: Add extensions() declaration.
(WebSocketImpl):


Canonical link: https://commits.webkit.org/97527@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@109889 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
toyoshim committed Mar 6, 2012
1 parent c703f5d commit 9e0fd7a
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 0 deletions.
15 changes: 15 additions & 0 deletions Source/WebKit/chromium/ChangeLog
@@ -1,3 +1,18 @@
2012-03-06 Takashi Toyoshima <toyoshim@chromium.org>

[Chromium] [WebSocket] Add WebSocket extensions query WebKit API
https://bugs.webkit.org/show_bug.cgi?id=80190

Reviewed by Darin Fisher.

* public/WebSocket.h: Add extensions() declaration.
(WebSocket):
* src/WebSocketImpl.cpp: Implement extensions() bridge.
(WebKit::WebSocketImpl::extensions):
(WebKit):
* src/WebSocketImpl.h: Add extensions() declaration.
(WebSocketImpl):

2012-03-05 Kent Tamura <tkent@chromium.org>

Do not reformat strings in <input type=number> on platforms using LocalizedNumberICU.
Expand Down
1 change: 1 addition & 0 deletions Source/WebKit/chromium/public/WebSocket.h
Expand Up @@ -80,6 +80,7 @@ class WebSocket {

virtual void connect(const WebURL&, const WebString& protocol) = 0;
virtual WebString subprotocol() = 0;
virtual WebString extensions() = 0;
virtual bool sendText(const WebString&) = 0;
virtual bool sendArrayBuffer(const WebArrayBuffer&) = 0;
virtual unsigned long bufferedAmount() const = 0;
Expand Down
9 changes: 9 additions & 0 deletions Source/WebKit/chromium/src/WebSocketImpl.cpp
Expand Up @@ -105,6 +105,15 @@ WebString WebSocketImpl::subprotocol()
#endif
}

WebString WebSocketImpl::extensions()
{
#if ENABLE(WEB_SOCKETS)
return m_private->extensions();
#else
ASSERT_NOT_REACHED();
#endif
}

bool WebSocketImpl::sendText(const WebString& message)
{
#if ENABLE(WEB_SOCKETS)
Expand Down
1 change: 1 addition & 0 deletions Source/WebKit/chromium/src/WebSocketImpl.h
Expand Up @@ -57,6 +57,7 @@ class WebSocketImpl : public WebSocket, public WebCore::WebSocketChannelClient {
virtual bool setBinaryType(BinaryType) OVERRIDE;
virtual void connect(const WebURL&, const WebString& protocol) OVERRIDE;
virtual WebString subprotocol() OVERRIDE;
virtual WebString extensions() OVERRIDE;
virtual bool sendText(const WebString&) OVERRIDE;
virtual bool sendArrayBuffer(const WebArrayBuffer&) OVERRIDE;
virtual unsigned long bufferedAmount() const OVERRIDE;
Expand Down

0 comments on commit 9e0fd7a

Please sign in to comment.