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

Side by Side Diff: third_party/WebKit/public/platform/modules/presentation/WebPresentationController.h

Issue 2355723004: [Presentation API] 1-UA: send message between controller and receiver page (Closed)
Patch Set: Merge with changes in Issue 2343013002 Created 4 years, 2 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 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef WebPresentationController_h 5 #ifndef WebPresentationController_h
6 #define WebPresentationController_h 6 #define WebPresentationController_h
7 7
8 #include "public/platform/WebCommon.h" 8 #include "public/platform/WebCommon.h"
9 #include "public/platform/modules/presentation/WebPresentationClient.h"
9 10
10 namespace blink { 11 namespace blink {
11 12
12 class WebPresentationConnectionClient;
13 class WebString; 13 class WebString;
14 enum class WebPresentationConnectionCloseReason; 14 enum class WebPresentationConnectionCloseReason;
15 enum class WebPresentationConnectionState; 15 enum class WebPresentationConnectionState;
16 16
17 // The delegate Blink provides to WebPresentationClient in order to get updates. 17 // The delegate Blink provides to WebPresentationClient in order to get updates.
18 class BLINK_PLATFORM_EXPORT WebPresentationController { 18 class BLINK_PLATFORM_EXPORT WebPresentationController : public WebPresentationMe ssageObserver {
19 public: 19 public:
20 virtual ~WebPresentationController() { } 20 virtual ~WebPresentationController() { }
21 21
22 // Called when the presentation session is started by the embedder using 22 // Called when the presentation session is started by the embedder using
23 // the default presentation URL and id. 23 // the default presentation URL and id.
24 virtual void didStartDefaultSession(WebPresentationConnectionClient*) = 0; 24 virtual void didStartDefaultSession(WebPresentationConnectionClient*) = 0;
25 25
26 // Called when the state of a session changes. 26 // Called when the state of a session changes.
27 virtual void didChangeSessionState(WebPresentationConnectionClient*, WebPres entationConnectionState) = 0; 27 virtual void didChangeSessionState(WebPresentationConnectionClient*, WebPres entationConnectionState) = 0;
28 28
29 // Called when a connection closes. 29 // Called when a connection closes.
30 virtual void didCloseConnection(WebPresentationConnectionClient*, WebPresent ationConnectionCloseReason, const WebString& message) = 0; 30 virtual void didCloseConnection(WebPresentationConnectionClient*, WebPresent ationConnectionCloseReason, const WebString& message) = 0;
31 31
32 // Called when a text message of a session is received. 32 // Called when a text message of a session is received.
33 virtual void didReceiveSessionTextMessage(WebPresentationConnectionClient*, const WebString& message) = 0; 33 virtual void didReceiveSessionTextMessage(WebPresentationConnectionClient*, const WebString& message) = 0;
34 34
35 // Called when a binary message of a session is received. 35 // Called when a binary message of a session is received.
36 virtual void didReceiveSessionBinaryMessage(WebPresentationConnectionClient* , const uint8_t* data, size_t length) = 0; 36 virtual void didReceiveSessionBinaryMessage(WebPresentationConnectionClient* , const uint8_t* data, size_t length) = 0;
37 }; 37 };
38 38
39 } // namespace blink 39 } // namespace blink
40 40
41 #endif // WebPresentationController_h 41 #endif // WebPresentationController_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698