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

Side by Side Diff: Source/modules/websockets/ThreadableWebSocketChannelClientWrapper.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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 42
43 class ThreadableWebSocketChannelClientWrapper : public ThreadSafeRefCountedWillB eGarbageCollected<ThreadableWebSocketChannelClientWrapper> { 43 class ThreadableWebSocketChannelClientWrapper : public ThreadSafeRefCountedWillB eGarbageCollected<ThreadableWebSocketChannelClientWrapper> {
44 public: 44 public:
45 static PassRefPtrWillBeRawPtr<ThreadableWebSocketChannelClientWrapper> creat e(WebSocketChannelClient*); 45 static PassRefPtrWillBeRawPtr<ThreadableWebSocketChannelClientWrapper> creat e(WebSocketChannelClient*);
46 46
47 void clearClient(); 47 void clearClient();
48 48
49 void didConnect(const String& subprotocol, const String& extensions); 49 void didConnect(const String& subprotocol, const String& extensions);
50 void didReceiveMessage(const String& message); 50 void didReceiveMessage(const String& message);
51 void didReceiveBinaryData(PassOwnPtr<Vector<char> >); 51 void didReceiveBinaryData(PassOwnPtr<Vector<char> >);
52 void didUpdateBufferedAmount(unsigned long bufferedAmount); 52 void didConsumeBufferedAmount(unsigned long);
53 void didStartClosingHandshake(); 53 void didStartClosingHandshake();
54 void didClose(unsigned long unhandledBufferedAmount, WebSocketChannelClient: :ClosingHandshakeCompletionStatus, unsigned short code, const String& reason); 54 void didClose(WebSocketChannelClient::ClosingHandshakeCompletionStatus, unsi gned short code, const String& reason);
55 void didReceiveMessageError(); 55 void didReceiveMessageError();
56 56
57 void trace(Visitor*) { } 57 void trace(Visitor*) { }
58 58
59 private: 59 private:
60 ThreadableWebSocketChannelClientWrapper(WebSocketChannelClient*); 60 ThreadableWebSocketChannelClientWrapper(WebSocketChannelClient*);
61 61
62 WebSocketChannelClient* m_client; 62 WebSocketChannelClient* m_client;
63 }; 63 };
64 64
65 } // namespace WebCore 65 } // namespace WebCore
66 66
67 #endif // ThreadableWebSocketChannelClientWrapper_h 67 #endif // ThreadableWebSocketChannelClientWrapper_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698