New issue
Advanced search Search tips

Issue 834319 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Task

Blocking:
issue 580406



Sign in to add a comment

[bluetooth] Migrate Bluetooth Implementation to OnceCallbacks

Project Member Reported by jdoerrie@chromium.org, Apr 18 2018

Issue description

Currently almost all interfaces in //device/bluetooth make use of the deprecated base::Callback. Many of these callbacks are only run once, it thus they should be migrated to base::OnceCallbacks instead.
 
Project Member

Comment 1 by bugdroid1@chromium.org, Apr 18 2018

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

commit cdbea2ac86c63bace4dd852b1cd4065f42542e6d
Author: Jan Wilken Doerrie <jdoerrie@chromium.org>
Date: Wed Apr 18 15:38:18 2018

[bluetooth] Run DiscoverySessionErrorCallback Once

This change changes BluetoothAdapter::DiscoverySessionErrorCallback from
base::Callback to base::OnceCallback. Furthermore, it updates relevant
methods to pass it by value and to std::move instances of the callback.

Bug:  821766 , 834319

Change-Id: Ibac2304c7540f2e9d80069ff19abb36ccbbd5527
Reviewed-on: https://chromium-review.googlesource.com/1013944
Commit-Queue: Jan Wilken Dörrie <jdoerrie@chromium.org>
Reviewed-by: Giovanni Ortuño Urquidi <ortuno@chromium.org>
Cr-Commit-Position: refs/heads/master@{#551686}
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_android.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_android.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_mac.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_mac.mm
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_unittest.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_win.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_win.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluetooth_adapter_win_unittest.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluez/bluetooth_adapter_bluez.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/bluez/bluetooth_adapter_bluez.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/cast/bluetooth_adapter_cast.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/cast/bluetooth_adapter_cast.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/dbus/bluetooth_adapter_client.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/dbus/bluetooth_adapter_client.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/dbus/fake_bluetooth_adapter_client.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/dbus/fake_bluetooth_adapter_client.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/test/fake_central.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/test/fake_central.h
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/test/mock_bluetooth_adapter.cc
[modify] https://crrev.com/cdbea2ac86c63bace4dd852b1cd4065f42542e6d/device/bluetooth/test/mock_bluetooth_adapter.h

Project Member

Comment 2 by bugdroid1@chromium.org, May 14 2018

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

commit 0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06
Author: Jan Wilken Doerrie <jdoerrie@chromium.org>
Date: Mon May 14 13:17:44 2018

[bluetooth] Make InitCallback a base::OnceClosure

This change turns BluetoothAdapter::InitCallback into a OnceClosure and
updates the corresponding subclasses.

Bug: 834319
Change-Id: I3ac35b38919320a30c332fbd156eb787c203db9f
Reviewed-on: https://chromium-review.googlesource.com/1050125
Commit-Queue: Jan Wilken Dörrie <jdoerrie@chromium.org>
Reviewed-by: Giovanni Ortuño Urquidi <ortuno@chromium.org>
Cr-Commit-Position: refs/heads/master@{#558279}
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter.cc
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter.h
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter_android.cc
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter_mac.mm
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter_stub.cc
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter_win.cc
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter_win.h
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter_winrt.cc
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluetooth_adapter_winrt.h
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluez/bluetooth_adapter_bluez.cc
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/bluez/bluetooth_adapter_bluez.h
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/cast/bluetooth_adapter_cast.cc
[modify] https://crrev.com/0b6af5d2f202f3c8ef1f80e44e9d6f0929833a06/device/bluetooth/test/bluetooth_test_win.cc

Sign in to add a comment