summaryrefslogtreecommitdiffstats
path: root/chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc
diff options
context:
space:
mode:
authorarmansito@chromium.org <armansito@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-23 16:49:14 +0000
committerarmansito@chromium.org <armansito@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-23 16:49:14 +0000
commit522f0fc0d9f130af95d197478945cb96b7d902b5 (patch)
treeefda0bdb052f1d4c3d7a5a02de15b2bee591d08d /chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc
parent3f571d0d68775728047fa40b522a5c38f4ae6a9e (diff)
downloadchromium_src-522f0fc0d9f130af95d197478945cb96b7d902b5.zip
chromium_src-522f0fc0d9f130af95d197478945cb96b7d902b5.tar.gz
chromium_src-522f0fc0d9f130af95d197478945cb96b7d902b5.tar.bz2
bluetoothLowEnergy: Send onServiceAdded after all characteristics are discovered
This CL makes the following changes: - Add support for the new "Characteristics" and "Descriptors" properties exposed under org.bluez.GattService1 and org.bluez.GattCharacteristic1, respectively. - Add device::BluetoothGattService::Observer::GattDiscoveryCompleteForService event, which gets called after the first PropertiesChanged signal is received for the "Characteristics" property of a service. - Change BluetoothLowEnergyEventRouter, so that it sends the "onServiceAdded" event not in GattServiceAdded but in GattDiscoveryCompleteForService. BUG=394537 TEST=browser_tests:BluetoothLowEnergyApiTest, device_unittests:BluetoothGattChromeOSTest Review URL: https://codereview.chromium.org/402303002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284955 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc')
-rw-r--r--chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc b/chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc
index 04745e6..3567567 100644
--- a/chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc
+++ b/chromeos/dbus/fake_bluetooth_gatt_characteristic_client.cc
@@ -294,6 +294,11 @@ void FakeBluetoothGattCharacteristicClient::ExposeHeartRateCharacteristics(
kClientCharacteristicConfigurationUUID));
DCHECK(ccc_path.IsValid());
heart_rate_measurement_ccc_desc_path_ = ccc_path.value();
+
+ std::vector<dbus::ObjectPath> desc_paths;
+ desc_paths.push_back(ccc_path);
+
+ heart_rate_measurement_properties_->descriptors.ReplaceValue(desc_paths);
}
void FakeBluetoothGattCharacteristicClient::HideHeartRateCharacteristics() {