Chromium Code Reviews| Index: device/bluetooth/bluetooth_audio_sink.h |
| diff --git a/device/bluetooth/bluetooth_audio_sink.h b/device/bluetooth/bluetooth_audio_sink.h |
| index 331ef0d83d1dac7653b745d899a694339ae7fce2..f3cca5387cf831223bd0bed6d5646aa3e1a96ae2 100644 |
| --- a/device/bluetooth/bluetooth_audio_sink.h |
| +++ b/device/bluetooth/bluetooth_audio_sink.h |
| @@ -40,8 +40,9 @@ class DEVICE_BLUETOOTH_EXPORT BluetoothAudioSink |
| // Possible types of error raised by Audio Sink object. |
| enum ErrorCode { |
| ERROR_UNSUPPORTED_PLATFORM, // A2DP sink not supported on current platform. |
| - ERROR_INVALID_ADAPTER, // BluetoothAdapter not presented/powered. |
| - ERROR_NOT_REGISTERED, // BluetoothAudioSink not registered. |
| + ERROR_INVALID_ADAPTER, // BluetoothAdapter not present/powered. |
| + ERROR_NOT_REGISTERED, // BluetoothAudioSink not registered. |
| + ERROR_NOT_UNREGISTERED, // BluetoothAudioSink not unregistered. |
| }; |
| // Options to configure an A2DP audio sink. |
| @@ -81,6 +82,10 @@ class DEVICE_BLUETOOTH_EXPORT BluetoothAudioSink |
| // is called. |
| typedef base::Callback<void(ErrorCode)> ErrorCallback; |
| + // Possible volumes for media transport are 0-127, and 128 is used to |
| + // represent invalid volume. |
| + static const uint16_t kInvalidVolume; |
| + |
| // Unregisters the audio sink. An audio sink will unregister itself |
| // automatically in its destructor, but calling Unregister is recommended, |
| // since user applications can be notified of an error returned by the call. |
| @@ -95,6 +100,9 @@ class DEVICE_BLUETOOTH_EXPORT BluetoothAudioSink |
| // Getters for state and volume. |
| virtual State GetState() const = 0; |
| + |
| + // Returns the current volume level of the audio sink. The possible volumes |
| + // are 0-128, where 0-127 are valid volumes and 128 represents invalid volume. |
|
armansito
2015/02/24 23:42:09
nit: Say that if volume is unknown, "kInvalidVolum
Miao
2015/02/26 02:17:46
Done.
|
| virtual uint16_t GetVolume() const = 0; |
| protected: |