| Index: chromeos/dbus/nfc_record_client.cc
|
| diff --git a/chromeos/dbus/nfc_record_client.cc b/chromeos/dbus/nfc_record_client.cc
|
| index 753d33fa9c95777e7409e54b55aeaffd430ee074..52573b972bce5e2da2a0480426a6d133ad1db39e 100644
|
| --- a/chromeos/dbus/nfc_record_client.cc
|
| +++ b/chromeos/dbus/nfc_record_client.cc
|
| @@ -187,11 +187,16 @@ class NfcRecordClientImpl : public NfcRecordClient,
|
| // nfc_client_helpers::DBusObjectMap::Delegate override.
|
| virtual NfcPropertySet* CreateProperties(
|
| dbus::ObjectProxy* object_proxy) OVERRIDE {
|
| - return new Properties(
|
| + Properties* properties = new Properties(
|
| object_proxy,
|
| base::Bind(&NfcRecordClientImpl::OnPropertyChanged,
|
| weak_ptr_factory_.GetWeakPtr(),
|
| object_proxy->object_path()));
|
| + properties->SetAllPropertiesReceivedCallback(
|
| + base::Bind(&NfcRecordClientImpl::OnPropertiesReceived,
|
| + weak_ptr_factory_.GetWeakPtr(),
|
| + object_proxy->object_path()));
|
| + return properties;
|
| }
|
|
|
| // nfc_client_helpers::DBusObjectMap::Delegate override.
|
| @@ -216,6 +221,14 @@ class NfcRecordClientImpl : public NfcRecordClient,
|
| RecordPropertyChanged(object_path, property_name));
|
| }
|
|
|
| + // Called by NfcPropertySet when all properties have been processed as a
|
| + // result of a call to GetAll.
|
| + void OnPropertiesReceived(const dbus::ObjectPath& object_path) {
|
| + VLOG(1) << "All record properties received; Path: " << object_path.value();
|
| + FOR_EACH_OBSERVER(NfcRecordClient::Observer, observers_,
|
| + RecordPropertiesReceived(object_path));
|
| + }
|
| +
|
| // We maintain a pointer to the bus to be able to request proxies for
|
| // new NFC records that appear.
|
| dbus::Bus* bus_;
|
|
|