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

Unified Diff: media/mojo/services/mojo_renderer_service.cc

Issue 2434413002: Plumb firstPartyForCookies() to MediaPlayerBridge (Closed)
Patch Set: Added bug number to TODO 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 side-by-side diff with in-line comments
Download patch
Index: media/mojo/services/mojo_renderer_service.cc
diff --git a/media/mojo/services/mojo_renderer_service.cc b/media/mojo/services/mojo_renderer_service.cc
index 50f6e56f82a4933070becdc9dd1553580e1e3632..22c9a833377e2c420ca172243b351f1f9eb849af 100644
--- a/media/mojo/services/mojo_renderer_service.cc
+++ b/media/mojo/services/mojo_renderer_service.cc
@@ -68,7 +68,8 @@ void MojoRendererService::Initialize(
mojom::RendererClientAssociatedPtrInfo client,
mojom::DemuxerStreamPtr audio,
mojom::DemuxerStreamPtr video,
- const base::Optional<GURL>& url,
+ const base::Optional<GURL>& media_url,
+ const base::Optional<GURL>& first_party_for_cookies,
const InitializeCallback& callback) {
DVLOG(1) << __FUNCTION__;
DCHECK_EQ(state_, STATE_UNINITIALIZED);
@@ -76,7 +77,7 @@ void MojoRendererService::Initialize(
client_.Bind(std::move(client));
state_ = STATE_INITIALIZING;
- if (url == base::nullopt) {
+ if (media_url == base::nullopt) {
stream_provider_.reset(new DemuxerStreamProviderShim(
std::move(audio), std::move(video),
base::Bind(&MojoRendererService::OnStreamReady, weak_this_, callback)));
@@ -85,8 +86,10 @@ void MojoRendererService::Initialize(
DCHECK(!audio);
DCHECK(!video);
- DCHECK(!url.value().is_empty());
- stream_provider_.reset(new MediaUrlDemuxer(nullptr, url.value()));
+ DCHECK(!media_url.value().is_empty());
+ DCHECK(first_party_for_cookies);
+ stream_provider_.reset(new MediaUrlDemuxer(nullptr, media_url.value(),
+ first_party_for_cookies.value()));
renderer_->Initialize(
stream_provider_.get(), this,
base::Bind(&MojoRendererService::OnRendererInitializeDone, weak_this_,
« media/base/media_url_params.h ('K') | « media/mojo/services/mojo_renderer_service.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698