2022-12-02 11:27:45 +01:00
|
|
|
using System.ComponentModel;
|
|
|
|
|
using System.Configuration;
|
|
|
|
|
|
|
|
|
|
namespace SteamController
|
|
|
|
|
{
|
2022-12-04 20:32:23 +01:00
|
|
|
|
2022-12-02 11:27:45 +01:00
|
|
|
[Category("Settings")]
|
|
|
|
|
[TypeConverter(typeof(ExpandableObjectConverter))]
|
|
|
|
|
internal sealed partial class Settings : ApplicationSettingsBase
|
|
|
|
|
{
|
|
|
|
|
public static readonly Settings Default = (Settings)Synchronized(new Settings());
|
|
|
|
|
|
|
|
|
|
public Settings()
|
|
|
|
|
{
|
|
|
|
|
PropertyChanged += delegate
|
|
|
|
|
{
|
|
|
|
|
Save();
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[UserScopedSetting]
|
|
|
|
|
[DefaultSettingValue("False")]
|
|
|
|
|
[BrowsableAttribute(false)]
|
|
|
|
|
public bool EnableSteamDetection
|
|
|
|
|
{
|
|
|
|
|
get { return ((bool)(this["EnableSteamDetection"])); }
|
|
|
|
|
set { this["EnableSteamDetection"] = value; }
|
|
|
|
|
}
|
|
|
|
|
|
2022-12-04 20:32:23 +01:00
|
|
|
[UserScopedSetting]
|
2022-12-02 11:27:45 +01:00
|
|
|
[DefaultSettingValue("Desktop")]
|
2022-12-04 20:32:23 +01:00
|
|
|
[Description("Default profile used when going back to Desktop mode")]
|
|
|
|
|
[BrowsableAttribute(true)]
|
|
|
|
|
public ProfilesSettings.Helpers.ProfileName DefaultProfile
|
2022-12-02 11:27:45 +01:00
|
|
|
{
|
2022-12-04 20:32:23 +01:00
|
|
|
get { return ((ProfilesSettings.Helpers.ProfileName)(this["DefaultProfile"])); }
|
|
|
|
|
set { this["DefaultProfile"] = value; }
|
2022-12-02 11:27:45 +01:00
|
|
|
}
|
|
|
|
|
|
2022-12-02 11:29:06 +01:00
|
|
|
#if DEBUG
|
|
|
|
|
[UserScopedSetting]
|
|
|
|
|
[BrowsableAttribute(true)]
|
|
|
|
|
#else
|
|
|
|
|
[ApplicationScopedSetting]
|
|
|
|
|
[BrowsableAttribute(false)]
|
|
|
|
|
#endif
|
|
|
|
|
[DefaultSettingValue("False")]
|
|
|
|
|
[DisplayName("Manage Steam Controller Configs")]
|
|
|
|
|
[Description("This does replace Steam configuration for controllers to prevent double inputs")]
|
|
|
|
|
public bool ManageSteamControllerConfigs
|
|
|
|
|
{
|
|
|
|
|
get { return ((bool)(this["ManageSteamControllerConfigs"])); }
|
|
|
|
|
set { this["ManageSteamControllerConfigs"] = value; }
|
|
|
|
|
}
|
|
|
|
|
|
2022-12-02 11:27:45 +01:00
|
|
|
public override string ToString()
|
|
|
|
|
{
|
|
|
|
|
return "";
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|