OLD | NEW |
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 CONTENT_PUBLIC_BROWSER_PRESENTATION_SERVICE_DELEGATE_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_PRESENTATION_SERVICE_DELEGATE_H_ |
6 #define CONTENT_PUBLIC_BROWSER_PRESENTATION_SERVICE_DELEGATE_H_ | 6 #define CONTENT_PUBLIC_BROWSER_PRESENTATION_SERVICE_DELEGATE_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <memory> | 9 #include <memory> |
10 #include <string> | 10 #include <string> |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
219 const PresentationSessionInfo& connection, | 219 const PresentationSessionInfo& connection, |
220 const PresentationConnectionStateChangedCallback& state_changed_cb) = 0; | 220 const PresentationConnectionStateChangedCallback& state_changed_cb) = 0; |
221 | 221 |
222 // Connect |controller_connection| owned by the controlling frame to the | 222 // Connect |controller_connection| owned by the controlling frame to the |
223 // offscreen presentation represented by |session|. | 223 // offscreen presentation represented by |session|. |
224 // |render_process_id|, |render_frame_id|: ID of originating frame. | 224 // |render_process_id|, |render_frame_id|: ID of originating frame. |
225 // |controller_connection|: Pointer to controller's presentation connection, | 225 // |controller_connection|: Pointer to controller's presentation connection, |
226 // ownership passed from controlling frame to the offscreen presentation. | 226 // ownership passed from controlling frame to the offscreen presentation. |
227 // |receiver_connection_request|: Mojo InterfaceRequest to be bind to receiver | 227 // |receiver_connection_request|: Mojo InterfaceRequest to be bind to receiver |
228 // page's presentation connection. | 228 // page's presentation connection. |
229 virtual void ConnectToOffscreenPresentation( | 229 virtual void ConnectToPresentation( |
230 int render_process_id, | 230 int render_process_id, |
231 int render_frame_id, | 231 int render_frame_id, |
232 const PresentationSessionInfo& session, | 232 const PresentationSessionInfo& session, |
233 PresentationConnectionPtr controller_connection_ptr, | 233 PresentationConnectionPtr controller_connection_ptr, |
234 PresentationConnectionRequest receiver_connection_request) = 0; | 234 PresentationConnectionRequest receiver_connection_request) = 0; |
235 }; | 235 }; |
236 | 236 |
237 // An interface implemented by embedders to handle | 237 // An interface implemented by embedders to handle |
238 // PresentationService calls from a presentation receiver. | 238 // PresentationService calls from a presentation receiver. |
239 class CONTENT_EXPORT ReceiverPresentationServiceDelegate | 239 class CONTENT_EXPORT ReceiverPresentationServiceDelegate |
240 : public PresentationServiceDelegate { | 240 : public PresentationServiceDelegate { |
241 public: | 241 public: |
242 // Registers a callback from the embedder when an offscreeen presentation has | 242 // Registers a callback from the embedder when an offscreeen presentation has |
243 // been successfully started. | 243 // been successfully started. |
244 // |receiver_available_callback|: Invoked when successfully starting a | 244 // |receiver_available_callback|: Invoked when successfully starting a |
245 // offscreen presentation session. | 245 // offscreen presentation session. |
246 virtual void RegisterReceiverConnectionAvailableCallback( | 246 virtual void RegisterReceiverConnectionAvailableCallback( |
247 const content::ReceiverConnectionAvailableCallback& | 247 const content::ReceiverConnectionAvailableCallback& |
248 receiver_available_callback) = 0; | 248 receiver_available_callback) = 0; |
249 }; | 249 }; |
250 | 250 |
251 } // namespace content | 251 } // namespace content |
252 | 252 |
253 #endif // CONTENT_PUBLIC_BROWSER_PRESENTATION_SERVICE_DELEGATE_H_ | 253 #endif // CONTENT_PUBLIC_BROWSER_PRESENTATION_SERVICE_DELEGATE_H_ |
OLD | NEW |