| Index: Source/modules/presentation/PresentationSession.h
|
| diff --git a/Source/modules/presentation/PresentationSession.h b/Source/modules/presentation/PresentationSession.h
|
| index be13d80c228bf4e8914b462042153500f6bab64a..da6e51d84fffac09afe5d1d641ad379e5a6d71da 100644
|
| --- a/Source/modules/presentation/PresentationSession.h
|
| +++ b/Source/modules/presentation/PresentationSession.h
|
| @@ -49,6 +49,9 @@ public:
|
| void send(Blob*, ExceptionState&);
|
| void close();
|
|
|
| + String binaryType() const;
|
| + void setBinaryType(const String&);
|
| +
|
| DEFINE_ATTRIBUTE_EVENT_LISTENER(message);
|
| DEFINE_ATTRIBUTE_EVENT_LISTENER(statechange);
|
|
|
| @@ -58,8 +61,9 @@ public:
|
| // Notifies the session about its state change.
|
| void didChangeState(WebPresentationSessionState);
|
|
|
| - // Notifies the session about new text message.
|
| + // Notifies the session about new message.
|
| void didReceiveTextMessage(const String& message);
|
| + void didReceiveBinaryMessage(const uint8_t* data, size_t length);
|
|
|
| private:
|
| class BlobLoader;
|
| @@ -70,6 +74,11 @@ private:
|
| MessageTypeBlob,
|
| };
|
|
|
| + enum BinaryType {
|
| + BinaryTypeBlob,
|
| + BinaryTypeArrayBuffer
|
| + };
|
| +
|
| struct Message {
|
| Message(const String& text)
|
| : type(MessageTypeText)
|
| @@ -105,6 +114,8 @@ private:
|
| // For Blob data handling.
|
| Member<BlobLoader> m_blobLoader;
|
| Deque<OwnPtr<Message>> m_messages;
|
| +
|
| + BinaryType m_binaryType;
|
| };
|
|
|
| } // namespace blink
|
|
|