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

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

Issue 2484273003: [Presentation API] (1-UA) fire PresentationConnection onterminate event if receiver page gets destr… (Closed)
Patch Set: resolve code review comments from haraken Created 4 years, 1 month 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 WebPresentationReceiver_h 5 #ifndef WebPresentationReceiver_h
6 #define WebPresentationReceiver_h 6 #define WebPresentationReceiver_h
7 7
8 #include "public/platform/WebCommon.h" 8 #include "public/platform/WebCommon.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 class WebPresentationConnectionClient; 12 class WebPresentationConnectionClient;
13 enum class WebPresentationConnectionState;
13 14
14 // The delegate Blink provides to WebPresentationReceiverClient in order to get 15 // The delegate Blink provides to WebPresentationReceiverClient in order to get
15 // updates. 16 // updates.
16 class BLINK_PLATFORM_EXPORT WebPresentationReceiver { 17 class BLINK_PLATFORM_EXPORT WebPresentationReceiver {
17 public: 18 public:
18 virtual ~WebPresentationReceiver() = default; 19 virtual ~WebPresentationReceiver() = default;
19 20
20 // Called when receiver page gets an incoming connection. 21 // Called when receiver page gets an incoming connection.
21 virtual void onReceiverConnectionAvailable( 22 virtual void onReceiverConnectionAvailable(
22 WebPresentationConnectionClient*) = 0; 23 WebPresentationConnectionClient*) = 0;
24
25 // Called when receiver page gets destroyed.
26 virtual void didChangeSessionState(WebPresentationConnectionState) = 0;
27
28 // Called when any PresentationConnection object on receiver page invokes
29 // connnection.terminate().
30 virtual void closeWindow() = 0;
23 }; 31 };
24 32
25 } // namespace blink 33 } // namespace blink
26 34
27 #endif // WebPresentationReceiver_h 35 #endif // WebPresentationReceiver_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698