| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 | 9 |
| 10 namespace chromeos { | 10 namespace chromeos { |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 // Returns the most-recently-set volume, in the range [0.0, 100.0]. | 22 // Returns the most-recently-set volume, in the range [0.0, 100.0]. |
| 23 virtual double GetVolumePercent() = 0; | 23 virtual double GetVolumePercent() = 0; |
| 24 | 24 |
| 25 // Sets the volume, possibly asynchronously. | 25 // Sets the volume, possibly asynchronously. |
| 26 // |percent| should be in the range [0.0, 100.0]. | 26 // |percent| should be in the range [0.0, 100.0]. |
| 27 virtual void SetVolumePercent(double percent) = 0; | 27 virtual void SetVolumePercent(double percent) = 0; |
| 28 | 28 |
| 29 // Is the device currently muted? | 29 // Is the device currently muted? |
| 30 virtual bool IsMuted() = 0; | 30 virtual bool IsMuted() = 0; |
| 31 | 31 |
| 32 // Mutes or unmutes the device, possibly asynchronously. | 32 // Mutes or unmutes the device, possibly asynchronously. The caller must |
| 33 // first verify that the mute state is not locked by calling IsMuteLocked. |
| 33 virtual void SetMuted(bool mute) = 0; | 34 virtual void SetMuted(bool mute) = 0; |
| 34 | 35 |
| 36 // Is the device's mute state currently locked? |
| 37 virtual bool IsMuteLocked() = 0; |
| 38 |
| 39 // Locks the mute state of the device to whatever state it currently is in. |
| 40 // Call SetMuteLocked with false to allow changing the mute state again. |
| 41 virtual void SetMuteLocked(bool locked) = 0; |
| 42 |
| 43 // Is the capture device currently muted? |
| 44 virtual bool IsCaptureMuted() = 0; |
| 45 |
| 46 // Mutes or unmutes the capture device, possible asynchronously. The caller |
| 47 // must first verify that the mute state is not locked by calling |
| 48 // IsCaptureMuteLocked. |
| 49 virtual void SetCaptureMuted(bool mute) = 0; |
| 50 |
| 51 // Is the capture device's mute state currently locked? |
| 52 virtual bool IsCaptureMuteLocked() = 0; |
| 53 |
| 54 // Locks the capture mute state of the device. |
| 55 virtual void SetCaptureMuteLocked(bool locked) = 0; |
| 56 |
| 35 private: | 57 private: |
| 36 DISALLOW_COPY_AND_ASSIGN(AudioMixer); | 58 DISALLOW_COPY_AND_ASSIGN(AudioMixer); |
| 37 }; | 59 }; |
| 38 | 60 |
| 39 } // namespace chromeos | 61 } // namespace chromeos |
| 40 | 62 |
| 41 #endif // CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ | 63 #endif // CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ |
| OLD | NEW |