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

Unified Diff: components/proximity_auth/ble/bluetooth_low_energy_connection.h

Issue 1912433002: Convert //components/proximity_auth from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits Created 4 years, 8 months 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: components/proximity_auth/ble/bluetooth_low_energy_connection.h
diff --git a/components/proximity_auth/ble/bluetooth_low_energy_connection.h b/components/proximity_auth/ble/bluetooth_low_energy_connection.h
index a80fe1d9696909888488786c4b717a7cb11b8799..7d0bb0b2c209f5b6b740a734ba5c79eaff1a830b 100644
--- a/components/proximity_auth/ble/bluetooth_low_energy_connection.h
+++ b/components/proximity_auth/ble/bluetooth_low_energy_connection.h
@@ -8,12 +8,12 @@
#include <stddef.h>
#include <stdint.h>
+#include <memory>
#include <queue>
#include <string>
#include "base/macros.h"
#include "base/memory/ref_counted.h"
-#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/time/time.h"
#include "components/proximity_auth/ble/bluetooth_low_energy_characteristics_finder.h"
@@ -117,7 +117,7 @@ class BluetoothLowEnergyConnection : public Connection,
error_callback);
// proximity_auth::Connection:
- void SendMessageImpl(scoped_ptr<WireMessage> message) override;
+ void SendMessageImpl(std::unique_ptr<WireMessage> message) override;
// device::BluetoothAdapter::Observer:
void DeviceChanged(device::BluetoothAdapter* adapter,
@@ -151,7 +151,7 @@ class BluetoothLowEnergyConnection : public Connection,
// Called when a GATT connection is created.
void OnGattConnectionCreated(
- scoped_ptr<device::BluetoothGattConnection> gatt_connection);
+ std::unique_ptr<device::BluetoothGattConnection> gatt_connection);
// Callback called when there is an error creating the GATT connection.
void OnCreateGattConnectionError(
@@ -175,7 +175,7 @@ class BluetoothLowEnergyConnection : public Connection,
// Called when a notification session is successfully started for
// |from_peripheral_char_| characteristic.
void OnNotifySessionStarted(
- scoped_ptr<device::BluetoothGattNotifySession> notify_session);
+ std::unique_ptr<device::BluetoothGattNotifySession> notify_session);
// Called when there is an error starting a notification session for
// |from_peripheral_char_| characteristic.
@@ -263,13 +263,14 @@ class BluetoothLowEnergyConnection : public Connection,
scoped_refptr<base::TaskRunner> task_runner_;
// The GATT connection with the remote device.
- scoped_ptr<device::BluetoothGattConnection> gatt_connection_;
+ std::unique_ptr<device::BluetoothGattConnection> gatt_connection_;
// The characteristics finder for remote device.
- scoped_ptr<BluetoothLowEnergyCharacteristicsFinder> characteristic_finder_;
+ std::unique_ptr<BluetoothLowEnergyCharacteristicsFinder>
+ characteristic_finder_;
// The notify session for |from_peripheral_char|.
- scoped_ptr<device::BluetoothGattNotifySession> notify_session_;
+ std::unique_ptr<device::BluetoothGattNotifySession> notify_session_;
// Internal connection status
SubStatus sub_status_;

Powered by Google App Engine
This is Rietveld 408576698