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

Unified Diff: device/bluetooth/bluetooth_local_gatt_characteristic.cc

Issue 1915803002: Bluetooth class changes for implementing local GATT attributes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: magic values fix 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: device/bluetooth/bluetooth_local_gatt_characteristic.cc
diff --git a/device/bluetooth/bluetooth_local_gatt_characteristic.cc b/device/bluetooth/bluetooth_local_gatt_characteristic.cc
index 9d4d37aac2372db8fbf23f5ac70740c920cf725a..873307d9eddecd57b0d2ba0072a632ef7010f80d 100644
--- a/device/bluetooth/bluetooth_local_gatt_characteristic.cc
+++ b/device/bluetooth/bluetooth_local_gatt_characteristic.cc
@@ -7,6 +7,10 @@
#include "base/logging.h"
#include "device/bluetooth/bluetooth_local_gatt_service.h"
+#if defined(OS_CHROMEOS) || defined(OS_LINUX)
+#include "device/bluetooth/bluez/bluetooth_local_gatt_characteristic_bluez.h"
+#endif
+
namespace device {
BluetoothLocalGattCharacteristic::BluetoothLocalGattCharacteristic() {}
@@ -14,14 +18,18 @@ BluetoothLocalGattCharacteristic::BluetoothLocalGattCharacteristic() {}
BluetoothLocalGattCharacteristic::~BluetoothLocalGattCharacteristic() {}
// static
-BluetoothLocalGattCharacteristic* BluetoothLocalGattCharacteristic::Create(
- const BluetoothUUID& uuid,
- const std::vector<uint8_t>& value,
- Properties properties,
- Permissions permissions,
- BluetoothLocalGattService* service) {
+base::WeakPtr<BluetoothLocalGattCharacteristic>
+BluetoothLocalGattCharacteristic::Create(const BluetoothUUID& uuid,
+ Properties properties,
+ Permissions permissions,
+ BluetoothLocalGattService* service) {
+#if defined(OS_CHROMEOS) || defined(OS_LINUX)
+ return bluez::BluetoothLocalGattCharacteristicBlueZ::Create(
scheib 2016/04/26 06:03:32 Place an impl of BluetoothLocalGattCharacteristic:
rkc 2016/04/26 18:23:59 Done.
+ uuid, properties, permissions, service);
+#else
NOTIMPLEMENTED();
- return NULL;
+ return nullptr;
+#endif
}
} // namespace device

Powered by Google App Engine
This is Rietveld 408576698