Chromium Code Reviews| Index: third_party/WebKit/Source/modules/presentation/PresentationConnection.h |
| diff --git a/third_party/WebKit/Source/modules/presentation/PresentationConnection.h b/third_party/WebKit/Source/modules/presentation/PresentationConnection.h |
| index 72fe6730858479e1c2f2a27b9e5707b1c4b24d5f..96ce49820e906664946ca1d5e2dfde84928bc42f 100644 |
| --- a/third_party/WebKit/Source/modules/presentation/PresentationConnection.h |
| +++ b/third_party/WebKit/Source/modules/presentation/PresentationConnection.h |
| @@ -11,6 +11,8 @@ |
| #include "core/fileapi/FileError.h" |
| #include "platform/heap/Handle.h" |
| #include "platform/weborigin/KURL.h" |
| +#include "public/platform/modules/presentation/WebPresentationConnection.h" |
| +#include "public/platform/modules/presentation/WebPresentationConnectionProxy.h" |
| #include "public/platform/modules/presentation/WebPresentationController.h" |
| #include "public/platform/modules/presentation/WebPresentationSessionInfo.h" |
| #include "wtf/text/WTFString.h" |
| @@ -29,7 +31,8 @@ class PresentationReceiver; |
| class PresentationRequest; |
| class PresentationConnection final : public EventTargetWithInlineData, |
| - public ContextClient { |
| + public ContextClient, |
| + public WebPresentationConnection { |
| USING_GARBAGE_COLLECTED_MIXIN(PresentationConnection); |
| DEFINE_WRAPPERTYPEINFO(); |
| @@ -45,6 +48,8 @@ class PresentationConnection final : public EventTargetWithInlineData, |
| const WebPresentationSessionInfo&); |
| ~PresentationConnection() override; |
| + void bindProxy(std::unique_ptr<WebPresentationConnectionProxy>) override; |
|
imcheng
2017/01/20 20:15:43
nit: group the override methods together and comme
zhaobin
2017/01/23 19:38:49
Done.
|
| + |
| // EventTarget implementation. |
| const AtomicString& interfaceName() const override; |
| ExecutionContext* getExecutionContext() const override; |
| @@ -79,14 +84,14 @@ class PresentationConnection final : public EventTargetWithInlineData, |
| bool matches(const String& id, const KURL&) const; |
| // Notifies the connection about its state change. |
| - void didChangeState(WebPresentationConnectionState); |
| + void didChangeState(WebPresentationConnectionState) override; |
| // Notifies the connection about its state change to 'closed'. |
| void didClose(WebPresentationConnectionCloseReason, const String& message); |
| // Notifies the presentation about new message. |
| - void didReceiveTextMessage(const String& message); |
| - void didReceiveBinaryMessage(const uint8_t* data, size_t length); |
| + void didReceiveTextMessage(const WebString& message) override; |
| + void didReceiveBinaryMessage(const uint8_t* data, size_t length) override; |
| WebPresentationConnectionState getState(); |
| @@ -133,6 +138,8 @@ class PresentationConnection final : public EventTargetWithInlineData, |
| HeapDeque<Member<Message>> m_messages; |
| BinaryType m_binaryType; |
| + |
| + std::unique_ptr<WebPresentationConnectionProxy> m_proxy; |
| }; |
| } // namespace blink |