1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef ASH_SYSTEM_AUDIO_TRAY_AUDIO_DELEGATE_H_
6 #define ASH_SYSTEM_AUDIO_TRAY_AUDIO_DELEGATE_H_
11 class ASH_EXPORT TrayAudioDelegate
{
14 enum { kNoAudioDeviceIcon
= -1 };
15 enum AudioChannelMode
{
20 virtual ~TrayAudioDelegate() {}
22 // Sets the volume level of the output device to the minimum level which is
23 // deemed to be audible.
24 virtual void AdjustOutputVolumeToAudibleLevel() = 0;
26 // Gets the default level in the range 0%-100% at which the output device
28 virtual int GetOutputDefaultVolumeMuteLevel() = 0;
30 // Gets the icon to use for the active output device.
31 virtual int GetActiveOutputDeviceIconId() = 0;
33 // Returns the volume level of the output device in the range 0%-100%.
34 virtual int GetOutputVolumeLevel() = 0;
36 // Returns true if the device has alternative inputs or outputs.
37 virtual bool HasAlternativeSources() = 0;
39 // Returns whether the output volume is muted.
40 virtual bool IsOutputAudioMuted() = 0;
42 // Sets the mute state of the output device.
43 virtual void SetOutputAudioIsMuted(bool is_muted
) = 0;
45 // Sets the volume level of the output device in the range 0%-100%
46 virtual void SetOutputVolumeLevel(int level
) = 0;
48 // Sets the internal speaker's channel mode.
49 virtual void SetInternalSpeakerChannelMode(AudioChannelMode mode
) = 0;
55 #endif // ASH_SYSTEM_AUDIO_TRAY_AUDIO_DELEGATE_H_