Chromium Code Reviews| 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. | |
| 34 // If SetMuteLocked has been called with true this function will not change | |
|
Daniel Erat
2012/08/29 17:35:10
nit: remove the "If SetMuteLocked has been called.
pastarmovj
2012/08/31 07:28:24
Done.
| |
| 35 // the mute state until it is unlocked with another call to | |
| 36 // SetMuteLocked(false). | |
| 33 virtual void SetMuted(bool mute) = 0; | 37 virtual void SetMuted(bool mute) = 0; |
| 34 | 38 |
| 39 // Is the device's mute state currently locked? | |
| 40 virtual bool IsMuteLocked() = 0; | |
| 41 | |
| 42 // Locks the mute state of the device to whatever state it currently is in. | |
| 43 // Call SetMuteLocked with false to allow changing the mute state again. | |
| 44 virtual void SetMuteLocked(bool locked) = 0; | |
| 45 | |
| 46 // Is the capture device currently muted? | |
| 47 virtual bool IsCaptureMuted() = 0; | |
| 48 | |
| 49 // Mutes or unmutes the capture device, possible asynchronously. The caller | |
| 50 // must first verify that the mute state is not locked by calling | |
| 51 // IsCaptureMuteLocked. | |
| 52 virtual void SetCaptureMuted(bool mute) = 0; | |
| 53 | |
| 54 // Is the capture device's mute state currently locked? | |
| 55 virtual bool IsCaptureMuteLocked() = 0; | |
| 56 | |
| 57 // Locks the capture mute state of the device. | |
| 58 virtual void SetCaptureMuteLocked(bool locked) = 0; | |
| 59 | |
| 35 private: | 60 private: |
| 36 DISALLOW_COPY_AND_ASSIGN(AudioMixer); | 61 DISALLOW_COPY_AND_ASSIGN(AudioMixer); |
| 37 }; | 62 }; |
| 38 | 63 |
| 39 } // namespace chromeos | 64 } // namespace chromeos |
| 40 | 65 |
| 41 #endif // CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ | 66 #endif // CHROME_BROWSER_CHROMEOS_AUDIO_AUDIO_MIXER_H_ |
| OLD | NEW |