summaryrefslogtreecommitdiffstats
path: root/chromeos/dbus/nfc_device_client.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chromeos/dbus/nfc_device_client.cc')
-rw-r--r--chromeos/dbus/nfc_device_client.cc38
1 files changed, 17 insertions, 21 deletions
diff --git a/chromeos/dbus/nfc_device_client.cc b/chromeos/dbus/nfc_device_client.cc
index 4b5281b..8d185c2 100644
--- a/chromeos/dbus/nfc_device_client.cc
+++ b/chromeos/dbus/nfc_device_client.cc
@@ -43,25 +43,25 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
DCHECK(adapter_client);
}
- virtual ~NfcDeviceClientImpl() {
+ ~NfcDeviceClientImpl() override {
DCHECK(adapter_client_);
adapter_client_->RemoveObserver(this);
}
// NfcDeviceClient override.
- virtual void AddObserver(NfcDeviceClient::Observer* observer) override {
+ void AddObserver(NfcDeviceClient::Observer* observer) override {
DCHECK(observer);
observers_.AddObserver(observer);
}
// NfcDeviceClient override.
- virtual void RemoveObserver(NfcDeviceClient::Observer* observer) override {
+ void RemoveObserver(NfcDeviceClient::Observer* observer) override {
DCHECK(observer);
observers_.RemoveObserver(observer);
}
// NfcDeviceClient override.
- virtual std::vector<dbus::ObjectPath> GetDevicesForAdapter(
+ std::vector<dbus::ObjectPath> GetDevicesForAdapter(
const dbus::ObjectPath& adapter_path) override {
DBusObjectMap* object_map =
adapters_to_object_maps_.GetObjectMap(adapter_path);
@@ -71,18 +71,16 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
}
// NfcDeviceClient override.
- virtual Properties* GetProperties(
- const dbus::ObjectPath& object_path) override {
+ Properties* GetProperties(const dbus::ObjectPath& object_path) override {
return static_cast<Properties*>(
adapters_to_object_maps_.FindObjectProperties(object_path));
}
// NfcDeviceClient override.
- virtual void Push(
- const dbus::ObjectPath& object_path,
- const base::DictionaryValue& attributes,
- const base::Closure& callback,
- const nfc_client_helpers::ErrorCallback& error_callback) override {
+ void Push(const dbus::ObjectPath& object_path,
+ const base::DictionaryValue& attributes,
+ const base::Closure& callback,
+ const nfc_client_helpers::ErrorCallback& error_callback) override {
dbus::ObjectProxy* object_proxy =
adapters_to_object_maps_.FindObjectProxy(object_path);
if (!object_proxy) {
@@ -120,7 +118,7 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
protected:
// DBusClient override.
- virtual void Init(dbus::Bus* bus) override {
+ void Init(dbus::Bus* bus) override {
VLOG(1) << "Creating NfcDeviceClientImpl";
DCHECK(bus);
bus_ = bus;
@@ -130,7 +128,7 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
private:
// NfcAdapterClient::Observer override.
- virtual void AdapterAdded(const dbus::ObjectPath& object_path) override {
+ void AdapterAdded(const dbus::ObjectPath& object_path) override {
VLOG(1) << "Adapter added. Creating map for device proxies belonging to "
<< "adapter: " << object_path.value();
adapters_to_object_maps_.CreateObjectMap(
@@ -138,7 +136,7 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
}
// NfcAdapterClient::Observer override.
- virtual void AdapterRemoved(const dbus::ObjectPath& object_path) override {
+ void AdapterRemoved(const dbus::ObjectPath& object_path) override {
// Neard doesn't send out property changed signals for the devices that
// are removed when the adapter they belong to is removed. Clean up the
// object proxies for devices that are managed by the removed adapter.
@@ -150,9 +148,8 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
}
// NfcAdapterClient::Observer override.
- virtual void AdapterPropertyChanged(
- const dbus::ObjectPath& object_path,
- const std::string& property_name) override {
+ void AdapterPropertyChanged(const dbus::ObjectPath& object_path,
+ const std::string& property_name) override {
DCHECK(adapter_client_);
NfcAdapterClient::Properties *adapter_properties =
adapter_client_->GetProperties(object_path);
@@ -173,8 +170,7 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
}
// nfc_client_helpers::DBusObjectMap::Delegate override.
- virtual NfcPropertySet* CreateProperties(
- dbus::ObjectProxy* object_proxy) override {
+ NfcPropertySet* CreateProperties(dbus::ObjectProxy* object_proxy) override {
return new Properties(
object_proxy,
base::Bind(&NfcDeviceClientImpl::OnPropertyChanged,
@@ -183,12 +179,12 @@ class NfcDeviceClientImpl : public NfcDeviceClient,
}
// nfc_client_helpers::DBusObjectMap::Delegate override.
- virtual void ObjectAdded(const dbus::ObjectPath& object_path) override {
+ void ObjectAdded(const dbus::ObjectPath& object_path) override {
FOR_EACH_OBSERVER(NfcDeviceClient::Observer, observers_,
DeviceAdded(object_path));
}
- virtual void ObjectRemoved(const dbus::ObjectPath& object_path) override {
+ void ObjectRemoved(const dbus::ObjectPath& object_path) override {
FOR_EACH_OBSERVER(NfcDeviceClient::Observer, observers_,
DeviceRemoved(object_path));
}