diff options
author | keybuk@chromium.org <keybuk@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-06-28 18:43:30 +0000 |
---|---|---|
committer | keybuk@chromium.org <keybuk@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-06-28 18:43:30 +0000 |
commit | 091e0b6f3daf32cf818c0f6bbe8cb0b57c1cf8fb (patch) | |
tree | 2fdf7eaa5a1bbad6129c18a833fade35c7a2b7f8 /chromeos/dbus/bluetooth_adapter_client.h | |
parent | 1d03024fbacc8f413ac104fec5ba1f5296b4b965 (diff) | |
download | chromium_src-091e0b6f3daf32cf818c0f6bbe8cb0b57c1cf8fb.zip chromium_src-091e0b6f3daf32cf818c0f6bbe8cb0b57c1cf8fb.tar.gz chromium_src-091e0b6f3daf32cf818c0f6bbe8cb0b57c1cf8fb.tar.bz2 |
dbus: move logic from Property<> to PropertySet
Rather than implement Get() and Set() in dbus::Property<> move the
code into dbus::PropertySet and pass a pointer to the property to
operate on from the wrapper call.
The advange of this way of doing things is that it's much easier to
make subclasses, since you only need to subclass dbus::PropertySet;
and ths makes it possible to mock.
BUG=chromium-os:28555
TEST=dbus_unittests
Change-Id: I760ca608d1e0a17422c11e0115c053d98be33fe0
R=satorux@chromium.org
Review URL: https://chromiumcodereview.appspot.com/10698027
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@144756 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chromeos/dbus/bluetooth_adapter_client.h')
-rw-r--r-- | chromeos/dbus/bluetooth_adapter_client.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/chromeos/dbus/bluetooth_adapter_client.h b/chromeos/dbus/bluetooth_adapter_client.h index 52c8692..62c00d5 100644 --- a/chromeos/dbus/bluetooth_adapter_client.h +++ b/chromeos/dbus/bluetooth_adapter_client.h @@ -33,51 +33,51 @@ class CHROMEOS_EXPORT BluetoothAdapterClient { // Structure of properties associated with bluetooth adapters. struct Properties : public BluetoothPropertySet { // The Bluetooth device address of the adapter. Read-only. - BluetoothProperty<std::string> address; + dbus::Property<std::string> address; // The Bluetooth friendly name of the adapter, unlike remote devices, // this property can be changed to change the presentation for when // the adapter is discoverable. - BluetoothProperty<std::string> name; + dbus::Property<std::string> name; // The Bluetooth class of the adapter device. Read-only. - BluetoothProperty<uint32> bluetooth_class; + dbus::Property<uint32> bluetooth_class; // Whether the adapter radio is powered. - BluetoothProperty<bool> powered; + dbus::Property<bool> powered; // Whether the adapter is discoverable by other Bluetooth devices. // |discovering_timeout| is used to automatically disable after a time // period. - BluetoothProperty<bool> discoverable; + dbus::Property<bool> discoverable; // Whether the adapter accepts incoming pairing requests from other // Bluetooth devices. |pairable_timeout| is used to automatically disable // after a time period. - BluetoothProperty<bool> pairable; + dbus::Property<bool> pairable; // The timeout in seconds to cease accepting incoming pairing requests // after |pairable| is set to true. Zero means adapter remains pairable // forever. - BluetoothProperty<uint32> pairable_timeout; + dbus::Property<uint32> pairable_timeout; // The timeout in seconds to cease the adapter being discoverable by // other Bluetooth devices after |discoverable| is set to true. Zero // means adapter remains discoverable forever. - BluetoothProperty<uint32> discoverable_timeout; + dbus::Property<uint32> discoverable_timeout; // Indicates that the adapter is discovering other Bluetooth Devices. // Read-only. Use StartDiscovery() to begin discovery. - BluetoothProperty<bool> discovering; + dbus::Property<bool> discovering; // List of object paths of known Bluetooth devices, known devices are // those that have previously been connected or paired or are currently // connected or paired. Read-only. - BluetoothProperty<std::vector<dbus::ObjectPath> > devices; + dbus::Property<std::vector<dbus::ObjectPath> > devices; // List of 128-bit UUIDs that represent the available local services. // Read-only. - BluetoothProperty<std::vector<std::string> > uuids; + dbus::Property<std::vector<std::string> > uuids; Properties(dbus::ObjectProxy* object_proxy, PropertyChangedCallback callback); |