New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 627655 link

Starred by 5 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: Jan 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 2
Type: Bug

Blocking:
issue 673664



Sign in to add a comment

[Presentation API] Add DOMString[] constructor for PresentationRequest

Project Member Reported by mfo...@chromium.org, Jul 12 2016

Issue description

This bug tracks the work to support multiple presentation URLs per PresentationRequest, per spec change [1].

[1] https://github.com/w3c/presentation-api/commit/b6abdde1bf3606c09a346b511ed5bfb791b7068e

imcheng@ has outlined the work necessary below.  I'm starting on the Blink side changes and will send out an I2S with the patch.

---

Blink to support multiple presentation URLs per PresentationRequest object
(Optional) enforce a Chrome-specific upper limit on number of URLs per request
Change PresentationAvailabilityCallbacks to handle multiple URLs
Change PresentationAvailability to handle multiple URLs
3+4 means PresentationDispatcher sends back the URL in addition to availability to callbacks/listeners
No change required downstream


start
PresentationDispatcher / PresentationService startSession to take multiple URLs
MR UI to support multiple presentation URLs
Multiple DEFAULT modes? Browser needs to pick a "default" DEFAULT mode URL.
No change to MediaRouter API and downstream

reconnect
PresentationDispatcher / PresentationService joinSession to take multiple URLs
Should we pass the URL list to the MRP and let them decide which one to use?


 

Comment 1 by mfo...@chromium.org, Jul 12 2016

Summary: [Presentation API] Add DOMString[] constructor for PresentationRequest (was: [Presentation API])
Project Member

Comment 2 by bugdroid1@chromium.org, Jul 29 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/59e7b40948030815a49af887b922b370ba048b8b

commit 59e7b40948030815a49af887b922b370ba048b8b
Author: mfoltz <mfoltz@chromium.org>
Date: Fri Jul 29 22:10:46 2016

[Presentation API] Convert presentation.mojom to new wrapper types.

This converts presentation.mojom to use the new (std::) Mojo wrapper types:
mojo::String => std::string
mojo::Array => std::vector

No behavior changes should ensue.

Optional values are represented as base::Optional<Foo> with the new wrapper
types requiring some additional changes.

This work will simplify further changes for  crbug.com/627655 .

BUG= 627655 

Review-Url: https://codereview.chromium.org/2181163003
Cr-Commit-Position: refs/heads/master@{#408781}

[modify] https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b/content/browser/presentation/presentation_service_impl.cc
[modify] https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b/content/browser/presentation/presentation_service_impl.h
[modify] https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b/content/browser/presentation/presentation_service_impl_unittest.cc
[modify] https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b/content/renderer/presentation/presentation_dispatcher.cc
[modify] https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b/content/renderer/presentation/presentation_dispatcher.h
[modify] https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b/third_party/WebKit/public/BUILD.gn
[modify] https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b/third_party/WebKit/public/blink.gyp

Project Member

Comment 3 by bugdroid1@chromium.org, Aug 1 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/43c746be32b2bfce5c3fd654894e4b7f7bf6387f

commit 43c746be32b2bfce5c3fd654894e4b7f7bf6387f
Author: tapted <tapted@chromium.org>
Date: Mon Aug 01 03:30:09 2016

Revert of [Presentation API] Convert presentation.mojom to new wrapper types. (patchset #5 id:80001 of https://codereview.chromium.org/2181163003/ )

Reason for revert:
Suspect (not the first) for widespread NaCl test failures since
https://build.chromium.org/p/chromium.win/builders/Win7%20Tests%20%281%29/builds/55504

Errors like

[4224:3200:0729/162247:ERROR:nacl_process_host.cc(337)] NaCl process exited with status -1073741674 (0xc0000096)
...
  Actual: "Plugin crashed. 'NaCl module crashed'"

Wasn't r408782 or r408787. Running out of candidates..

Original issue's description:
> [Presentation API] Convert presentation.mojom to new wrapper types.
>
> This converts presentation.mojom to use the new (std::) Mojo wrapper types:
> mojo::String => std::string
> mojo::Array => std::vector
>
> No behavior changes should ensue.
>
> Optional values are represented as base::Optional<Foo> with the new wrapper
> types requiring some additional changes.
>
> This work will simplify further changes for  crbug.com/627655 .
>
> BUG= 627655 
>
> Committed: https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b
> Cr-Commit-Position: refs/heads/master@{#408781}

TBR=dcheng@chromium.org,imcheng@chromium.org,mfoltz@chromium.org
NOTRY=true
BUG= 627655 

Review-Url: https://codereview.chromium.org/2196143002
Cr-Commit-Position: refs/heads/master@{#408905}

[modify] https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f/content/browser/presentation/presentation_service_impl.cc
[modify] https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f/content/browser/presentation/presentation_service_impl.h
[modify] https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f/content/browser/presentation/presentation_service_impl_unittest.cc
[modify] https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f/content/renderer/presentation/presentation_dispatcher.cc
[modify] https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f/content/renderer/presentation/presentation_dispatcher.h
[modify] https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f/third_party/WebKit/public/BUILD.gn
[modify] https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f/third_party/WebKit/public/blink.gyp

Project Member

Comment 4 by bugdroid1@chromium.org, Aug 1 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8f125bddde53e2988f244ec4e31a92d247340488

commit 8f125bddde53e2988f244ec4e31a92d247340488
Author: tapted <tapted@chromium.org>
Date: Mon Aug 01 04:51:09 2016

Reland of [Presentation API] Convert presentation.mojom to new wrapper types. (patchset #1 id:1 of https://codereview.chromium.org/2196143002/ )

Reason for revert:
Didn't work. NaCl still crashing. Sadness :(

Original issue's description:
> Revert of [Presentation API] Convert presentation.mojom to new wrapper types. (patchset #5 id:80001 of https://codereview.chromium.org/2181163003/ )
>
> Reason for revert:
> Suspect (not the first) for widespread NaCl test failures since
> https://build.chromium.org/p/chromium.win/builders/Win7%20Tests%20%281%29/builds/55504
>
> Errors like
>
> [4224:3200:0729/162247:ERROR:nacl_process_host.cc(337)] NaCl process exited with status -1073741674 (0xc0000096)
> ...
>   Actual: "Plugin crashed. 'NaCl module crashed'"
>
> Wasn't r408782 or r408787. Running out of candidates..
>
> Original issue's description:
> > [Presentation API] Convert presentation.mojom to new wrapper types.
> >
> > This converts presentation.mojom to use the new (std::) Mojo wrapper types:
> > mojo::String => std::string
> > mojo::Array => std::vector
> >
> > No behavior changes should ensue.
> >
> > Optional values are represented as base::Optional<Foo> with the new wrapper
> > types requiring some additional changes.
> >
> > This work will simplify further changes for  crbug.com/627655 .
> >
> > BUG= 627655 
> >
> > Committed: https://crrev.com/59e7b40948030815a49af887b922b370ba048b8b
> > Cr-Commit-Position: refs/heads/master@{#408781}
>
> TBR=dcheng@chromium.org,imcheng@chromium.org,mfoltz@chromium.org
> NOTRY=true
> BUG= 627655 
>
> Committed: https://crrev.com/43c746be32b2bfce5c3fd654894e4b7f7bf6387f
> Cr-Commit-Position: refs/heads/master@{#408905}

TBR=dcheng@chromium.org,imcheng@chromium.org,mfoltz@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG= 627655 

Review-Url: https://codereview.chromium.org/2197053002
Cr-Commit-Position: refs/heads/master@{#408910}

[modify] https://crrev.com/8f125bddde53e2988f244ec4e31a92d247340488/content/browser/presentation/presentation_service_impl.cc
[modify] https://crrev.com/8f125bddde53e2988f244ec4e31a92d247340488/content/browser/presentation/presentation_service_impl.h
[modify] https://crrev.com/8f125bddde53e2988f244ec4e31a92d247340488/content/browser/presentation/presentation_service_impl_unittest.cc
[modify] https://crrev.com/8f125bddde53e2988f244ec4e31a92d247340488/content/renderer/presentation/presentation_dispatcher.cc
[modify] https://crrev.com/8f125bddde53e2988f244ec4e31a92d247340488/content/renderer/presentation/presentation_dispatcher.h
[modify] https://crrev.com/8f125bddde53e2988f244ec4e31a92d247340488/third_party/WebKit/public/BUILD.gn
[modify] https://crrev.com/8f125bddde53e2988f244ec4e31a92d247340488/third_party/WebKit/public/blink.gyp

The build in question seems to have recovered.  Not sure if there was a different fix landed for the underlying problem.

https://build.chromium.org/p/chromium.win/builders/Win7%20Tests%20%281%29/builds/55672
Project Member

Comment 6 by bugdroid1@chromium.org, Sep 3 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fcad5262059e8b20621dd601a44ea5383b04cca0

commit fcad5262059e8b20621dd601a44ea5383b04cca0
Author: mfoltz <mfoltz@chromium.org>
Date: Sat Sep 03 03:08:33 2016

[Presentation API] Add support to content/ for multiple URLs per PresentationRequest.

This is the first part of a multi-part series of patches:

   1   This patch
   2-N Additional support in Blink, Media Router, UX, etc.
   N+1 https://codereview.chromium.org/2148643002 with Intent to Implement+Ship

This patch:

- Adds support to WebPresentationClient for passing multiple URLs to startSession/joinSession/setDefaultPresentationUrls
- Updates PresentationService mojo interface
- Updates PresentationServiceImpl/PresentationServiceDispatcher
- Passes a single URL from Blink to WebPresentationClient
- Passes a single URL from PresentationServiceDispatcherImpl to MR
- Updates unittests

BUG= 627655 

Review-Url: https://codereview.chromium.org/2174693004
Cr-Commit-Position: refs/heads/master@{#416433}

[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/chrome/browser/media/router/presentation_service_delegate_impl.cc
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/chrome/browser/media/router/presentation_service_delegate_impl.h
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/chrome/browser/media/router/presentation_service_delegate_impl_unittest.cc
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/browser/presentation/OWNERS
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/browser/presentation/presentation_service_impl.cc
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/browser/presentation/presentation_service_impl.h
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/browser/presentation/presentation_service_impl_unittest.cc
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/browser/presentation/presentation_type_converters.h
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/browser/presentation/presentation_type_converters_unittest.cc
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/public/browser/presentation_service_delegate.h
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/renderer/presentation/presentation_connection_client.cc
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/renderer/presentation/presentation_connection_client.h
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/renderer/presentation/presentation_dispatcher.cc
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/renderer/presentation/presentation_dispatcher.h
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/content/test/BUILD.gn
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/third_party/WebKit/Source/modules/presentation/PresentationController.cpp
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/third_party/WebKit/public/platform/modules/presentation/WebPresentationClient.h
[modify] https://crrev.com/fcad5262059e8b20621dd601a44ea5383b04cca0/third_party/WebKit/public/platform/modules/presentation/presentation.mojom

Labels: -M-54 M-55
Project Member

Comment 8 by bugdroid1@chromium.org, Sep 28 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/4f8671de022b8908686fc5667039c4288a7eeb70

commit 4f8671de022b8908686fc5667039c4288a7eeb70
Author: takumif <takumif@chromium.org>
Date: Wed Sep 28 01:16:04 2016

[Presentation API] Add support for multiple URLs in PresentationRequest on Media Router UI side

Relevant CL:
https://codereview.chromium.org/2174693004/

This CL:
- MediaRouterUI now gets multiple sources from PresentationRequest and passes them onto QueryResultManager
- QueryResultManager keeps track of not only which cast modes a sink supports, but also which sources for each cast mode
- QueryResultManager::MediaSourceMediaSinksObserver observes changes in sinks compatibility of a source rather than a cast mode
- QueryResultManager::SetSourcesForCastMode() takes multiple media sources per cast mode
- QueryResultManager::GetSourceForCastModeAndSink() (was GetSourceForCastMode()) requires you to specify the sink, because different sinks may support different sources for the same cast mode
- Add/fix unit tests for QueryResultManager and MediaRouterUI
- Add a class CastModesWithMediaSources used by QueryResultManager for storing cast modes and sources (and unit tests for it).

BUG= 627655 

Review-Url: https://codereview.chromium.org/2264153002
Cr-Commit-Position: refs/heads/master@{#421412}

[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/android/router/media_router_dialog_controller_android.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/create_presentation_connection_request.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/create_presentation_connection_request.h
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/create_presentation_connection_request_unittest.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/media_sink.h
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/media_source.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/media_source.h
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/mojo/media_router_type_converters_unittest.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/presentation_media_sinks_observer.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/presentation_media_sinks_observer.h
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/presentation_request.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/presentation_request.h
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/presentation_request_unittest.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/presentation_service_delegate_impl.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/media/router/presentation_service_delegate_impl_unittest.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/BUILD.gn
[add] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/cast_modes_with_media_sources.cc
[add] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/cast_modes_with_media_sources.h
[add] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/cast_modes_with_media_sources_unittest.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/media_router_ui.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/media_router_ui_unittest.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/query_result_manager.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/query_result_manager.h
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/browser/ui/webui/media_router/query_result_manager_unittest.cc
[modify] https://crrev.com/4f8671de022b8908686fc5667039c4288a7eeb70/chrome/test/BUILD.gn

Labels: -M-55 M-56
Labels: PresentationAPI
Here's the layout of the remaining work for tracking purposes.

src/chrome/browser/media/router/presentation_request.h

- Need to update it to return vector<GURL> and update all callers.
- In PDSImpl, we are re-using the PresentationRequest to invoke callbacks with the route response.  We should update these APIs to take a route request object that uses a single URL/source.

src/chrome/browser/ui/webui/media_router/media_router_ui.cc

I don't believe this is easily fixable with the current concept of "joinable route ids" that are tied to the media source.  I think this will require some specific handling for Cast but any hacks can be isolated in the UI layer.

src/chrome/browser/media/router/presentation_service_delegate_impl.cc

The supporting classes inside PSDImpl just need to handle multiple URLs.  Pretty straightforward.

src/third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp
src/third_party/WebKit/Source/modules/presentation/PresentationController.cpp
These are already handled in https://codereview.chromium.org/2148643002, an old patch that needs to be rebased.

src/chrome/browser/media/android/router/media_router_dialog_controller_android.cc

The Android implementation doesn't seem to have a way to match sinks with sources so unclear how to solve this generically.  May have to add some specific handling here and punt until the design is better understood.

Also, updating unit and integration tests.

Mark will you wrap this up for M56?  If not please update milestone.
Labels: -M-56 M-57
Project Member

Comment 14 by bugdroid1@chromium.org, Dec 7 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/81cb26bf6bad31e3f5858c43d828e689d3b789f4

commit 81cb26bf6bad31e3f5858c43d828e689d3b789f4
Author: zhaobin <zhaobin@chromium.org>
Date: Wed Dec 07 19:42:55 2016

[Media Router] Handle multiple Presentation URLs when creating routes

Based on https://codereview.chromium.org/2488403002/

- Implement CanConnectToMediaSource() in media_source_helper.cc
- In PresentationServiceDelegateImpl::JoinSession, pick cast specific url and send it to cast MRP

BUG= 627655 

Review-Url: https://codereview.chromium.org/2547703002
Cr-Commit-Position: refs/heads/master@{#437035}

[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/create_presentation_connection_request.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/create_presentation_connection_request.h
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/create_presentation_connection_request_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/media_router_dialog_controller_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/media_source.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/media_source.h
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/media_source_helper.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/media_source_helper.h
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/media_source_helper_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/media_source_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/presentation_request.h
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/presentation_request_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/presentation_service_delegate_impl.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/presentation_service_delegate_impl_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/route_request_result.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/media/router/route_request_result.h
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/ui/webui/media_router/media_router_dialog_controller_impl_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/ui/webui/media_router/media_router_ui.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/browser/ui/webui/media_router/media_router_ui_unittest.cc
[modify] https://crrev.com/81cb26bf6bad31e3f5858c43d828e689d3b789f4/chrome/test/media_router/resources/common.js

Blocking: 673664
Project Member

Comment 16 by bugdroid1@chromium.org, Jan 17 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894

commit ad0eb0fa0ba570b4e41e28383dda35d1aca0a894
Author: zhaobin <zhaobin@chromium.org>
Date: Tue Jan 17 21:25:47 2017

[Presentation API] Adds DOMString[] constructor to PresentationRequest.

Applying https://codereview.chromium.org/2148643002/

This updates the Blink and platform layers of the Presentation API to support multiple URLs per PresentationRequest.  Until support is plumbed through to the service layer, only the first URL in the array will be passed through the PresentationService API.

This also:

- Updates layout tests to exercise the new constructor
- Adds a unit test to PresentationRequest
- Updates PresentationAvailabilityTest
- Adds a 'url' attribute to PresentationConnection
- Moves mixed-content check to PresentationRequest ctor

BUG= 627655 , 673942 , 654110 

Review-Url: https://codereview.chromium.org/2552343009
Cr-Commit-Position: refs/heads/master@{#444148}

[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/chrome/test/media_router/resources/common.js
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/content/renderer/presentation/presentation_dispatcher.cc
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/content/renderer/presentation/presentation_dispatcher.h
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/content/renderer/presentation/presentation_dispatcher_unittest.cc
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/platform/linux/virtual/stable/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/platform/win/virtual/stable/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/presentation/presentation-api.html
[add] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/presentation/presentation-navigation-multipleurls.html
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/presentation/presentation-reconnect.html
[add] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/presentation/presentation-start.html
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/presentation/presentationconnectionavailableevent-ctor-mock.html
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/presentation/presentationrequest.html
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/presentation/resources/presentation-service-mock.js
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/virtual/stable/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/BUILD.gn
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/Presentation.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationAvailability.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationAvailability.h
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationAvailabilityCallbacks.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationAvailabilityCallbacks.h
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationAvailabilityTest.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationConnection.h
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationConnection.idl
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationController.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationController.h
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationReceiverTest.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationRequest.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationRequest.h
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationRequest.idl
[add] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/Source/modules/presentation/PresentationRequestTest.cpp
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/public/platform/modules/presentation/WebPresentationAvailabilityObserver.h
[modify] https://crrev.com/ad0eb0fa0ba570b4e41e28383dda35d1aca0a894/third_party/WebKit/public/platform/modules/presentation/WebPresentationClient.h

Owner: zhaobin@chromium.org
Project Member

Comment 18 by bugdroid1@chromium.org, Jan 21 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9bc9d0de59b3d141441fae948fd09298fcfb5f75

commit 9bc9d0de59b3d141441fae948fd09298fcfb5f75
Author: zhaobin <zhaobin@chromium.org>
Date: Sat Jan 21 07:13:58 2017

[Presentation API] Handle multiple Presentation URLs in PresentationRequest::getAvailability()

- Handle muliple URLs in getAvailability(), startListening(), and stopListening()
- When screen availability for a particular url comes back, update all PresentationRequests related to this url
- Added PresentationDispatcherUnittest

BUG= 627655 

Review-Url: https://codereview.chromium.org/2598063002
Cr-Commit-Position: refs/heads/master@{#445278}

[modify] https://crrev.com/9bc9d0de59b3d141441fae948fd09298fcfb5f75/content/renderer/presentation/presentation_dispatcher.cc
[modify] https://crrev.com/9bc9d0de59b3d141441fae948fd09298fcfb5f75/content/renderer/presentation/presentation_dispatcher.h
[modify] https://crrev.com/9bc9d0de59b3d141441fae948fd09298fcfb5f75/content/renderer/presentation/presentation_dispatcher_unittest.cc

Status: Fixed (was: Started)
Labels: -PresentationAPI
Cc: mlamouri@chromium.org
Hey, are there plans to fix Android or should I take a stab on it? 
https://cs.chromium.org/chromium/src/chrome/browser/media/android/router/media_router_dialog_controller_android.cc?
rcl=fe00e8f82df4a3dd7dd0ec9cc6a7097506d45e65&l=52

There's another TODO with a link to this bug in it (about joining routes) so it feels a little strange to have the bug marked as fixed :)
Filed  Bug 734639  to unblock web platform tests.  It wasn't clear at the time how to implement this on Android - hopefully you have some context here :-)

Sign in to add a comment