| Index: chrome/browser/media/router/presentation_service_delegate_impl.cc
|
| diff --git a/chrome/browser/media/router/presentation_service_delegate_impl.cc b/chrome/browser/media/router/presentation_service_delegate_impl.cc
|
| index 581357dced0c7900c4062f72870482a748830424..55565fbf921135bef91be8f2036fc12f0477582b 100644
|
| --- a/chrome/browser/media/router/presentation_service_delegate_impl.cc
|
| +++ b/chrome/browser/media/router/presentation_service_delegate_impl.cc
|
| @@ -21,6 +21,8 @@
|
| #include "chrome/browser/media/router/media_router_factory.h"
|
| #include "chrome/browser/media/router/media_sink.h"
|
| #include "chrome/browser/media/router/media_source_helper.h"
|
| +#include "chrome/browser/media/router/offscreen_presentation_manager.h"
|
| +#include "chrome/browser/media/router/offscreen_presentation_manager_factory.h"
|
| #include "chrome/browser/media/router/presentation_media_sinks_observer.h"
|
| #include "chrome/browser/media/router/route_message.h"
|
| #include "chrome/browser/media/router/route_message_observer.h"
|
| @@ -666,9 +668,13 @@ PresentationServiceDelegateImpl::PresentationServiceDelegateImpl(
|
| router_(MediaRouterFactory::GetApiForBrowserContext(
|
| web_contents_->GetBrowserContext())),
|
| frame_manager_(new PresentationFrameManager(web_contents, router_)),
|
| + m_offscreenPresentationManager(
|
| + OffscreenPresentationManagerFactory::GetOrCreateForBrowserContext(
|
| + web_contents_->GetBrowserContext())),
|
| weak_factory_(this) {
|
| DCHECK(web_contents_);
|
| DCHECK(router_);
|
| + DCHECK(m_offscreenPresentationManager);
|
| }
|
|
|
| PresentationServiceDelegateImpl::~PresentationServiceDelegateImpl() {
|
| @@ -966,4 +972,18 @@ bool PresentationServiceDelegateImpl::HasScreenAvailabilityListenerForTest(
|
| render_frame_host_id, source_id);
|
| }
|
|
|
| +void PresentationServiceDelegateImpl::RegisterOffscreenPresentationController(
|
| + const std::string& presentation_id,
|
| + content::OffscreenPresentationClient* client) {
|
| + m_offscreenPresentationManager->RegisterOffscreenPresentationController(
|
| + presentation_id, client);
|
| +}
|
| +
|
| +void PresentationServiceDelegateImpl::UnregisterOffscreenPresentationController(
|
| + const std::string& presentation_id,
|
| + content::OffscreenPresentationClient* client) {
|
| + m_offscreenPresentationManager->UnregisterOffscreenPresentationController(
|
| + presentation_id, client);
|
| +}
|
| +
|
| } // namespace media_router
|
|
|