Add SteamController implementation

This adds a Steam Shortcuts, Desktop Mode, and X360 Emulation
- Supports all Steam Shortcuts (including on-screen keyboard, and brightness)
- Supports Desktop mode (with a scroll on left pad and left stick), and trackpoint (on right stick)
- Supports X360 mode: hold Options for 1s to switch between Desktop and X360
- Holding Steam button enables Desktop like controls and stops passing all inputs to X360
This commit is contained in:
Kamil Trzciński 2022-11-24 22:37:24 +01:00
parent 203338b669
commit ecbd0407c0
41 changed files with 2486 additions and 34 deletions

View file

@ -12,6 +12,14 @@ namespace PowerControl.Helpers
/// </summary>
public static class WindowsSettingsBrightnessController
{
public static void Increase(int brightness)
{
var current = Get();
current += brightness;
current = Math.Clamp(current, 0, 100);
Set(current);
}
public static int Get(double roundValue = 10.0)
{
return (int)(Math.Round(Get() / roundValue) * roundValue);