Index: content/public/browser/presentation_service_delegate.h |
diff --git a/content/public/browser/presentation_service_delegate.h b/content/public/browser/presentation_service_delegate.h |
index cbe2c5f1cc9c5c64cbc46d32beb5b1cca81c4950..76c4a648b8ec0decb3a69b78fed0d090ab61e5bd 100644 |
--- a/content/public/browser/presentation_service_delegate.h |
+++ b/content/public/browser/presentation_service_delegate.h |
@@ -14,6 +14,7 @@ |
#include "content/common/content_export.h" |
#include "content/public/browser/presentation_session.h" |
#include "content/public/browser/presentation_session_message.h" |
+#include "third_party/WebKit/public/platform/modules/presentation/presentation.mojom.h" |
namespace content { |
@@ -47,6 +48,12 @@ struct PresentationConnectionStateChangeInfo { |
using PresentationConnectionStateChangedCallback = |
base::Callback<void(const PresentationConnectionStateChangeInfo&)>; |
+using PresentationConnectionPtr = blink::mojom::PresentationConnectionPtr; |
+ |
+using ReceiverConnectionAvailableCallback = |
+ base::Callback<void(const content::PresentationSessionInfo&, |
+ PresentationConnectionPtr&&)>; |
+ |
// An interface implemented by embedders to handle presentation API calls |
// forwarded from PresentationServiceImpl. |
class CONTENT_EXPORT PresentationServiceDelegate { |
@@ -203,6 +210,28 @@ class CONTENT_EXPORT PresentationServiceDelegate { |
int render_frame_id, |
const PresentationSessionInfo& connection, |
const PresentationConnectionStateChangedCallback& state_changed_cb) = 0; |
+ |
+ // In receiverPSDImpl, register receiver_available_callback with |
mark a. foltz
2016/10/08 00:33:42
The ReceiverPDSImpl is part of chrome/browser; so
zhaobin
2016/10/12 02:27:33
Done.
|
+ // OffscreenPresentationManager; |
+ // In controllerPSDImpl, no-op. |
+ // |receiver_available_callback|: Invoked when successfully starting a |
+ // offscreen presentation session. |
+ virtual void RegisterReceiverAvailableCallback( |
+ const content::ReceiverConnectionAvailableCallback& |
+ receiver_available_callback) = 0; |
+ |
+ // In receiverPSDImpl, no-op; |
+ // In controllerPSDImpl, register controller presentation connection mojo |
+ // object to OffscreenPresentationManager (OPM). |
+ // |render_process_id|, |render_frame_id|: ID of originating frame. |
+ // |connection|: Pointer to controller presentation connection, |
+ // pass ownership to OPM. To be used in |
+ // offscreen_presentation_manager->RegisterOffscreenPresentationController(). |
mark a. foltz
2016/10/08 00:33:42
// Connect |connection| owned by the controlling f
zhaobin
2016/10/12 02:27:33
Done.
|
+ virtual void RegisterOffscreenPresentationConnection( |
+ int render_process_id, |
+ int render_frame_id, |
+ const PresentationSessionInfo& session, |
+ PresentationConnectionPtr connection) = 0; |
}; |
} // namespace content |