microsoft/TypeAgent
Publicmirrored fromhttps://github.com/microsoft/TypeAgentAvailable
dotnet/autoShell/Services/IAudioService.cs
30lines · modecode
| 1 | // Copyright (c) Microsoft Corporation. |
| 2 | // Licensed under the MIT License. |
| 3 | |
| 4 | namespace autoShell.Services; |
| 5 | |
| 6 | /// <summary> |
| 7 | /// Abstracts Windows Core Audio API operations for testability. |
| 8 | /// </summary> |
| 9 | internal interface IAudioService |
| 10 | { |
| 11 | /// <summary> |
| 12 | /// Sets the system volume to the specified percentage (0–100). |
| 13 | /// </summary> |
| 14 | void SetVolume(int percent); |
| 15 | |
| 16 | /// <summary> |
| 17 | /// Gets the current system volume as a percentage (0–100). |
| 18 | /// </summary> |
| 19 | int GetVolume(); |
| 20 | |
| 21 | /// <summary> |
| 22 | /// Sets or clears the system mute state. |
| 23 | /// </summary> |
| 24 | void SetMute(bool mute); |
| 25 | |
| 26 | /// <summary> |
| 27 | /// Gets the current system mute state. |
| 28 | /// </summary> |
| 29 | bool GetMute(); |
| 30 | } |
| 31 | |