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

Issue 1286063002: Add a path for content/ to open and control a Bluetooth chooser dialog. (Closed)

Created:
5 years, 4 months ago by Jeffrey Yasskin
Modified:
5 years, 4 months ago
CC:
asvitkine+watch_chromium.org, chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, jam, nasko+codewatch_chromium.org, Finnur, scheib, ncarter (slow)
Base URL:
https://chromium.googlesource.com/chromium/src.git@lkcr
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add a path for content/ to open and control a Bluetooth chooser dialog. This obsoletes several histogram values, and some of the corner-case error states won't be well tested until I add the ability for layout tests to manage dialog states. 2nd of 3 patches: 1. Add errors and prepare tests. (https://codereview.chromium.org/1293593003/) 2. Wire up the chooser on the Chrome side. (This patch) 3. Update the test assertions and remove now-unused errors. (https://codereview.chromium.org/1284143006/) BUG=500989, 517237 Committed: https://crrev.com/5e7aec4faea108b6e64ee6a4712e77ca5b43e3c7 Cr-Commit-Position: refs/heads/master@{#345541}

Patch Set 1 #

Patch Set 2 : With tests except requestDevice.html passing #

Patch Set 3 : Tests pass! TODO: clean up #

Patch Set 4 : Clean up. #

Total comments: 25

Patch Set 5 : Fix Gio's comments #

Total comments: 2

Patch Set 6 : Comments in BluetoothDispatcherHost::CloseDialog #

Patch Set 7 : Remove an unnecessary include and forward decl #

Total comments: 10

Patch Set 8 : Fix half of jam's comments. #

Patch Set 9 : Use a callback function with an enum instead of an observer. #

Total comments: 6

Patch Set 10 : Fix asvitkine's comments. #

Total comments: 4

Patch Set 11 : Move chooser default to BluetoothDispatcherHost. #

Total comments: 2

Patch Set 12 : Fix comment wrapping. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+481 lines, -147 lines) Patch
M content/browser/bad_message.h View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M content/browser/bluetooth/bluetooth_dispatcher_host.h View 1 2 3 4 5 6 7 8 9 5 chunks +32 lines, -12 lines 0 comments Download
M content/browser/bluetooth/bluetooth_dispatcher_host.cc View 1 2 3 4 5 6 7 8 9 10 11 8 chunks +262 lines, -123 lines 0 comments Download
M content/browser/bluetooth/bluetooth_metrics.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +6 lines, -4 lines 0 comments Download
A content/browser/bluetooth/first_device_bluetooth_chooser.h View 1 2 3 4 5 6 7 8 9 1 chunk +39 lines, -0 lines 0 comments Download
A content/browser/bluetooth/first_device_bluetooth_chooser.cc View 1 2 3 4 5 6 7 8 1 chunk +46 lines, -0 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 4 5 6 7 8 9 10 2 chunks +4 lines, -0 lines 0 comments Download
A content/public/browser/bluetooth_chooser.h View 1 2 3 4 5 6 7 8 9 10 1 chunk +66 lines, -0 lines 0 comments Download
A + content/public/browser/bluetooth_chooser.cc View 1 2 3 1 chunk +2 lines, -2 lines 0 comments Download
M content/public/browser/web_contents_delegate.h View 1 2 3 4 5 6 7 8 2 chunks +8 lines, -0 lines 0 comments Download
M content/public/browser/web_contents_delegate.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +7 lines, -0 lines 0 comments Download
M tools/metrics/histograms/histograms.xml View 1 2 3 4 5 6 7 8 9 10 2 chunks +8 lines, -5 lines 0 comments Download

Messages

Total messages: 33 (11 generated)
Jeffrey Yasskin
5 years, 4 months ago (2015-08-14 23:00:10 UTC) #2
ortuno
Mostly questions. https://codereview.chromium.org/1286063002/diff/60001/content/browser/bluetooth/bluetooth_dispatcher_host.cc File content/browser/bluetooth/bluetooth_dispatcher_host.cc (right): https://codereview.chromium.org/1286063002/diff/60001/content/browser/bluetooth/bluetooth_dispatcher_host.cc#newcode138 content/browser/bluetooth/bluetooth_dispatcher_host.cc:138: discovery_session->Stop(base::Bind(&base::DoNothing), Should we at least log or ...
5 years, 4 months ago (2015-08-17 21:12:59 UTC) #4
Jeffrey Yasskin
I also fixed some comments, and reordered some things to try to make the dialog ...
5 years, 4 months ago (2015-08-17 23:38:16 UTC) #5
ortuno
LGTM https://codereview.chromium.org/1286063002/diff/60001/content/public/browser/bluetooth_chooser.h File content/public/browser/bluetooth_chooser.h (right): https://codereview.chromium.org/1286063002/diff/60001/content/public/browser/bluetooth_chooser.h#newcode49 content/public/browser/bluetooth_chooser.h:49: virtual void ShowDiscovering(DiscoveryState state) = 0; On 2015/08/17 ...
5 years, 4 months ago (2015-08-18 00:21:55 UTC) #6
Jeffrey Yasskin
Alexei, please look at histograms.xml. John, please look at content/*. Do you want us to ...
5 years, 4 months ago (2015-08-18 21:13:20 UTC) #8
Jeffrey Yasskin
+Nick too, but I'd like to check this in before he gets back on Aug ...
5 years, 4 months ago (2015-08-18 21:14:52 UTC) #9
Jeffrey Yasskin
Ping. John, are you the right person to review content/*, or should I find someone ...
5 years, 4 months ago (2015-08-20 15:37:30 UTC) #10
Alexei Svitkine (slow)
lgtm
5 years, 4 months ago (2015-08-24 17:18:04 UTC) #12
jam
https://codereview.chromium.org/1286063002/diff/120001/content/browser/bluetooth/bluetooth_dispatcher_host.cc File content/browser/bluetooth/bluetooth_dispatcher_host.cc (right): https://codereview.chromium.org/1286063002/diff/120001/content/browser/bluetooth/bluetooth_dispatcher_host.cc#newcode375 content/browser/bluetooth/bluetooth_dispatcher_host.cc:375: session->chooser = render_frame_host->RunBluetoothChooser( instead of going through RenderFrameHost->RenderFrameHostDelegate->WebContents->WebContentsDelegate, how ...
5 years, 4 months ago (2015-08-25 15:49:21 UTC) #14
Jeffrey Yasskin
https://codereview.chromium.org/1286063002/diff/120001/content/browser/bluetooth/bluetooth_dispatcher_host.cc File content/browser/bluetooth/bluetooth_dispatcher_host.cc (right): https://codereview.chromium.org/1286063002/diff/120001/content/browser/bluetooth/bluetooth_dispatcher_host.cc#newcode375 content/browser/bluetooth/bluetooth_dispatcher_host.cc:375: session->chooser = render_frame_host->RunBluetoothChooser( On 2015/08/25 15:49:21, jam wrote: > ...
5 years, 4 months ago (2015-08-25 17:13:14 UTC) #15
Jeffrey Yasskin
Ready for another review. https://codereview.chromium.org/1286063002/diff/120001/content/public/browser/bluetooth_chooser.h File content/public/browser/bluetooth_chooser.h (right): https://codereview.chromium.org/1286063002/diff/120001/content/public/browser/bluetooth_chooser.h#newcode28 content/public/browser/bluetooth_chooser.h:28: // those knobs will cause ...
5 years, 4 months ago (2015-08-25 20:55:58 UTC) #17
Alexei Svitkine (slow)
still lgtm https://codereview.chromium.org/1286063002/diff/180001/content/browser/bluetooth/first_device_bluetooth_chooser.h File content/browser/bluetooth/first_device_bluetooth_chooser.h (right): https://codereview.chromium.org/1286063002/diff/180001/content/browser/bluetooth/first_device_bluetooth_chooser.h#newcode20 content/browser/bluetooth/first_device_bluetooth_chooser.h:20: FirstDeviceBluetoothChooser(const EventHandler& event_handler); explicit https://codereview.chromium.org/1286063002/diff/180001/content/browser/bluetooth/first_device_bluetooth_chooser.h#newcode23 content/browser/bluetooth/first_device_bluetooth_chooser.h:23: // ...
5 years, 4 months ago (2015-08-25 20:59:23 UTC) #18
Jeffrey Yasskin
https://codereview.chromium.org/1286063002/diff/180001/content/browser/bluetooth/first_device_bluetooth_chooser.h File content/browser/bluetooth/first_device_bluetooth_chooser.h (right): https://codereview.chromium.org/1286063002/diff/180001/content/browser/bluetooth/first_device_bluetooth_chooser.h#newcode20 content/browser/bluetooth/first_device_bluetooth_chooser.h:20: FirstDeviceBluetoothChooser(const EventHandler& event_handler); On 2015/08/25 20:59:23, Alexei Svitkine (OOO ...
5 years, 4 months ago (2015-08-25 21:04:50 UTC) #19
jam
lgtm https://codereview.chromium.org/1286063002/diff/200001/content/public/browser/bluetooth_chooser.h File content/public/browser/bluetooth_chooser.h (right): https://codereview.chromium.org/1286063002/diff/200001/content/public/browser/bluetooth_chooser.h#newcode42 content/public/browser/bluetooth_chooser.h:42: // |observer| must outlive |this|. |chooser_id| is propagated ...
5 years, 4 months ago (2015-08-25 23:45:51 UTC) #20
Jeffrey Yasskin
https://codereview.chromium.org/1286063002/diff/200001/content/public/browser/bluetooth_chooser.h File content/public/browser/bluetooth_chooser.h (right): https://codereview.chromium.org/1286063002/diff/200001/content/public/browser/bluetooth_chooser.h#newcode42 content/public/browser/bluetooth_chooser.h:42: // |observer| must outlive |this|. |chooser_id| is propagated to ...
5 years, 4 months ago (2015-08-26 00:19:01 UTC) #21
scheib
LGTM, but noticed: https://codereview.chromium.org/1286063002/diff/220001/content/browser/bluetooth/bluetooth_dispatcher_host.cc File content/browser/bluetooth/bluetooth_dispatcher_host.cc (right): https://codereview.chromium.org/1286063002/diff/220001/content/browser/bluetooth/bluetooth_dispatcher_host.cc#newcode719 content/browser/bluetooth/bluetooth_dispatcher_host.cc:719: // asked comment wrapping
5 years, 4 months ago (2015-08-26 01:02:15 UTC) #23
Jeffrey Yasskin
https://codereview.chromium.org/1286063002/diff/220001/content/browser/bluetooth/bluetooth_dispatcher_host.cc File content/browser/bluetooth/bluetooth_dispatcher_host.cc (right): https://codereview.chromium.org/1286063002/diff/220001/content/browser/bluetooth/bluetooth_dispatcher_host.cc#newcode719 content/browser/bluetooth/bluetooth_dispatcher_host.cc:719: // asked On 2015/08/26 01:02:15, scheib wrote: > comment ...
5 years, 4 months ago (2015-08-26 01:11:11 UTC) #24
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1286063002/240001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1286063002/240001
5 years, 4 months ago (2015-08-26 01:12:58 UTC) #26
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_chromium_asan_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_asan_rel_ng/builds/44627)
5 years, 4 months ago (2015-08-26 02:37:08 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1286063002/240001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1286063002/240001
5 years, 4 months ago (2015-08-26 04:08:11 UTC) #31
commit-bot: I haz the power
Committed patchset #12 (id:240001)
5 years, 4 months ago (2015-08-26 04:46:56 UTC) #32
commit-bot: I haz the power
5 years, 4 months ago (2015-08-26 04:47:36 UTC) #33
Message was sent while issue was closed.
Patchset 12 (id:??) landed as
https://crrev.com/5e7aec4faea108b6e64ee6a4712e77ca5b43e3c7
Cr-Commit-Position: refs/heads/master@{#345541}

Powered by Google App Engine
This is Rietveld 408576698