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

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

Issue 311993006: [WebSocket] bufferedAmount should not decrease inside a task. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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/WebSocketChannelClient.h
diff --git a/Source/modules/websockets/WebSocketChannelClient.h b/Source/modules/websockets/WebSocketChannelClient.h
index aa942aacb656d0d587a01faa7674a088f0ba6c3b..5bcba20e6cc0dca6661cd40ccf20fef118bca870 100644
--- a/Source/modules/websockets/WebSocketChannelClient.h
+++ b/Source/modules/websockets/WebSocketChannelClient.h
@@ -37,24 +37,28 @@
namespace WebCore {
- class WebSocketChannelClient {
- public:
- virtual ~WebSocketChannelClient() { }
- virtual void didConnect() { }
- virtual void didReceiveMessage(const String&) { }
- virtual void didReceiveBinaryData(PassOwnPtr<Vector<char> >) { }
- virtual void didReceiveMessageError() { }
- virtual void didUpdateBufferedAmount(unsigned long /* bufferedAmount */) { }
- virtual void didStartClosingHandshake() { }
- enum ClosingHandshakeCompletionStatus {
- ClosingHandshakeIncomplete,
- ClosingHandshakeComplete
- };
- virtual void didClose(unsigned long /* unhandledBufferedAmount */, ClosingHandshakeCompletionStatus, unsigned short /* code */, const String& /* reason */) { }
-
- protected:
- WebSocketChannelClient() { }
+class WebSocketChannelClient {
+public:
+ virtual ~WebSocketChannelClient() { }
+ virtual void didConnect() { }
+ virtual void didReceiveMessage(const String&) { }
+ virtual void didReceiveBinaryData(PassOwnPtr<Vector<char> >) { }
+ virtual void didReceiveMessageError() { }
+ // These two functions are devided in order to keep the WebSocket API:
tyoshino (SeeGerritForStatus) 2014/06/09 09:24:26 keep -> follow? and how about s/API/API spec/
yhirano 2014/06/09 11:59:51 Done.
+ // The amount should be exposed immediately and the amount should
+ // be exposed behind.
tyoshino (SeeGerritForStatus) 2014/06/09 09:24:26 couldn't get the meaning of this.
yhirano 2014/06/09 11:59:51 Done.
+ virtual void didIncreaseBufferedAmount(unsigned long amountOfIncrease) { }
+ virtual void didDecreaseBufferedAmount(unsigned long amountOfDecrease) { }
+ virtual void didStartClosingHandshake() { }
+ enum ClosingHandshakeCompletionStatus {
+ ClosingHandshakeIncomplete,
+ ClosingHandshakeComplete
};
+ virtual void didClose(unsigned long /* unhandledBufferedAmount */, ClosingHandshakeCompletionStatus, unsigned short /* code */, const String& /* reason */) { }
+
+protected:
+ WebSocketChannelClient() { }
+};
} // namespace WebCore

Powered by Google App Engine
This is Rietveld 408576698