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

Issue 2108973002: [Media Router] Return NotFoundError on dialog exit if appropriate (Closed)

Created:
4 years, 5 months ago by btolsch
Modified:
4 years, 5 months ago
Reviewers:
imcheng
CC:
chromium-reviews, media-router+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Media Router] Return NotFoundError on dialog exit if appropriate The MR dialog will always be opened when starting a PresentationRequest, even if there are no sinks that support the presentation url. The default cast mode will then be some form of mirroring. This means that whether the user selects a device in the dialog or not, the promise from start() will be rejected with an AbortError. Instead, a NotFoundError should be used if there were no devices which supported the presentation url. BUG=621161 Committed: https://crrev.com/21d9a27daad3d0f6c3a9ad15818a099c728a3b3c Cr-Commit-Position: refs/heads/master@{#403336}

Patch Set 1 #

Total comments: 5

Patch Set 2 : Address nits, add unit tests, add integration test #

Total comments: 6

Patch Set 3 : Address comments, add no-sinks integration test, update test data json format #

Unified diffs Side-by-side diffs Delta from patch set Stats (+188 lines, -12 lines) Patch
M chrome/browser/ui/webui/media_router/media_router_ui.h View 1 1 chunk +3 lines, -1 line 0 comments Download
M chrome/browser/ui/webui/media_router/media_router_ui.cc View 1 2 chunks +24 lines, -6 lines 0 comments Download
M chrome/browser/ui/webui/media_router/media_router_ui_unittest.cc View 1 2 5 chunks +105 lines, -2 lines 0 comments Download
M chrome/test/media_router/BUILD.gn View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/test/media_router/media_router_integration_browsertest.cc View 1 2 1 chunk +35 lines, -0 lines 0 comments Download
M chrome/test/media_router/media_router_tests.gypi View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/test/media_router/resources/README.md View 1 2 1 chunk +8 lines, -3 lines 0 comments Download
A chrome/test/media_router/resources/no_sinks.json View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
A chrome/test/media_router/resources/no_supported_sinks.json View 1 2 1 chunk +6 lines, -0 lines 0 comments Download

Messages

Total messages: 12 (3 generated)
btolsch
Checking the sinks in ~MediaRouterUI() seems like the least intrusive solution, but let me know ...
4 years, 5 months ago (2016-06-28 23:43:31 UTC) #2
imcheng
lgtm. Putting it in ~MediaRouterUI sounds reasonable given that's when the dialog is being closed. ...
4 years, 5 months ago (2016-06-29 17:28:03 UTC) #3
btolsch
PTAL at the tests and the new MediaRouterUI::InitForTest, thanks! https://codereview.chromium.org/2108973002/diff/1/chrome/browser/ui/webui/media_router/media_router_ui.cc File chrome/browser/ui/webui/media_router/media_router_ui.cc (right): https://codereview.chromium.org/2108973002/diff/1/chrome/browser/ui/webui/media_router/media_router_ui.cc#newcode206 chrome/browser/ui/webui/media_router/media_router_ui.cc:206: ...
4 years, 5 months ago (2016-06-30 07:29:16 UTC) #4
imcheng
https://codereview.chromium.org/2108973002/diff/1/chrome/browser/ui/webui/media_router/media_router_ui.cc File chrome/browser/ui/webui/media_router/media_router_ui.cc (right): https://codereview.chromium.org/2108973002/diff/1/chrome/browser/ui/webui/media_router/media_router_ui.cc#newcode211 chrome/browser/ui/webui/media_router/media_router_ui.cc:211: return sink.cast_modes.find(MediaCastMode::DEFAULT) != On 2016/06/30 07:29:16, btolsch wrote: > ...
4 years, 5 months ago (2016-06-30 18:24:46 UTC) #5
btolsch
I updated the test data format to match where the other CL is now and ...
4 years, 5 months ago (2016-06-30 21:22:27 UTC) #6
imcheng
lgtm
4 years, 5 months ago (2016-06-30 22:07:18 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2108973002/40001
4 years, 5 months ago (2016-06-30 23:24:56 UTC) #9
commit-bot: I haz the power
Committed patchset #3 (id:40001)
4 years, 5 months ago (2016-06-30 23:31:24 UTC) #10
commit-bot: I haz the power
4 years, 5 months ago (2016-06-30 23:32:56 UTC) #12
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/21d9a27daad3d0f6c3a9ad15818a099c728a3b3c
Cr-Commit-Position: refs/heads/master@{#403336}

Powered by Google App Engine
This is Rietveld 408576698