mirror of
https://github.com/ayufan/steam-deck-tools.git
synced 2026-04-05 06:15:26 +00:00
Add Haptic feedback and selectable profiles
This commit is contained in:
parent
d0b6fb93b0
commit
bad617549e
15 changed files with 356 additions and 45 deletions
|
|
@ -455,6 +455,32 @@ namespace PowerControl
|
|||
return null;
|
||||
return selected;
|
||||
}
|
||||
},
|
||||
new Menu.MenuItemWithOptions()
|
||||
{
|
||||
Name = "Controller",
|
||||
ApplyDelay = 500,
|
||||
OptionsValues = delegate()
|
||||
{
|
||||
if (SharedData<SteamControllerSetting>.GetExistingValue(out var value))
|
||||
return value.SelectableProfiles.SplitWithN();
|
||||
return null;
|
||||
},
|
||||
CurrentValue = delegate()
|
||||
{
|
||||
if (SharedData<SteamControllerSetting>.GetExistingValue(out var value))
|
||||
return value.CurrentProfile.Length > 0 ? value.CurrentProfile : null;
|
||||
return null;
|
||||
},
|
||||
ApplyValue = delegate(object selected)
|
||||
{
|
||||
if (!SharedData<SteamControllerSetting>.GetExistingValue(out var value))
|
||||
return null;
|
||||
value.DesiredProfile = (String)selected;
|
||||
if (!SharedData<SteamControllerSetting>.SetExistingValue(value))
|
||||
return null;
|
||||
return selected;
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue