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

Unified Diff: device/bluetooth/bluetooth_low_energy_win.cc

Issue 2567903004: Replace ScopedVector/ScopedPtrHashMap with std::vector and std::unordered_map (Closed)
Patch Set: Created 4 years 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: device/bluetooth/bluetooth_low_energy_win.cc
diff --git a/device/bluetooth/bluetooth_low_energy_win.cc b/device/bluetooth/bluetooth_low_energy_win.cc
index 29abbad9eef86626b24e792fdd7cacd6d2078dbb..4fffb032370557cad7a7b72fae12715653f16da7 100644
--- a/device/bluetooth/bluetooth_low_energy_win.cc
+++ b/device/bluetooth/bluetooth_low_energy_win.cc
@@ -372,7 +372,7 @@ bool CollectBluetoothLowEnergyDeviceStatus(
bool CollectBluetoothLowEnergyDeviceServices(
const base::FilePath& device_path,
- ScopedVector<BluetoothLowEnergyServiceInfo>* services,
+ std::vector<std::unique_ptr<BluetoothLowEnergyServiceInfo>> services,
std::string* error) {
base::File file(device_path, base::File::FLAG_OPEN | base::File::FLAG_READ);
if (!file.IsValid()) {
@@ -542,7 +542,7 @@ HRESULT OpenBluetoothLowEnergyDevices(GUID device_interface_guid,
// Gatt service devices.
bool EnumerateKnownBLEOrBLEGattServiceDevices(
GUID guid,
- ScopedVector<BluetoothLowEnergyDeviceInfo>* devices,
+ std::vector<std::unique_ptr<BluetoothLowEnergyDeviceInfo>> devices,
std::string* error) {
ScopedDeviceInfoSetHandle info_set_handle;
HRESULT hr = OpenBluetoothLowEnergyDevices(guid, &info_set_handle);
@@ -678,7 +678,7 @@ bool BluetoothLowEnergyWrapper::IsBluetoothLowEnergySupported() {
}
bool BluetoothLowEnergyWrapper::EnumerateKnownBluetoothLowEnergyDevices(
- ScopedVector<BluetoothLowEnergyDeviceInfo>* devices,
+ std::vector<std::unique_ptr<BluetoothLowEnergyDeviceInfo>> devices,
std::string* error) {
if (!IsBluetoothLowEnergySupported()) {
*error = kPlatformNotSupported;
@@ -691,7 +691,7 @@ bool BluetoothLowEnergyWrapper::EnumerateKnownBluetoothLowEnergyDevices(
bool BluetoothLowEnergyWrapper::
EnumerateKnownBluetoothLowEnergyGattServiceDevices(
- ScopedVector<BluetoothLowEnergyDeviceInfo>* devices,
+ std::vector<std::unique_ptr<BluetoothLowEnergyDeviceInfo>> devices,
std::string* error) {
if (!IsBluetoothLowEnergySupported()) {
*error = kPlatformNotSupported;
@@ -704,7 +704,7 @@ bool BluetoothLowEnergyWrapper::
bool BluetoothLowEnergyWrapper::EnumerateKnownBluetoothLowEnergyServices(
const base::FilePath& device_path,
- ScopedVector<BluetoothLowEnergyServiceInfo>* services,
+ std::vector<std::unique_ptr<BluetoothLowEnergyServiceInfo>>& services,
std::string* error) {
if (!IsBluetoothLowEnergySupported()) {
*error = kPlatformNotSupported;

Powered by Google App Engine
This is Rietveld 408576698