mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 02:42:54 +08:00
Merge pull request #11961 from frenzibyte/fix-sensitivity-globally-disabled
This commit is contained in:
commit
a0ccfa8129
@ -880,13 +880,8 @@ namespace osu.Game
|
||||
switch (action)
|
||||
{
|
||||
case GlobalAction.ResetInputSettings:
|
||||
var sensitivity = frameworkConfig.GetBindable<double>(FrameworkSetting.CursorSensitivity);
|
||||
|
||||
sensitivity.Disabled = false;
|
||||
sensitivity.Value = 1;
|
||||
sensitivity.Disabled = true;
|
||||
|
||||
frameworkConfig.Set(FrameworkSetting.IgnoredInputHandlers, string.Empty);
|
||||
frameworkConfig.GetBindable<string>(FrameworkSetting.IgnoredInputHandlers).SetDefault();
|
||||
frameworkConfig.GetBindable<double>(FrameworkSetting.CursorSensitivity).SetDefault();
|
||||
frameworkConfig.GetBindable<ConfineMouseMode>(FrameworkSetting.ConfineMouseMode).SetDefault();
|
||||
return true;
|
||||
|
||||
|
@ -76,7 +76,15 @@ namespace osu.Game.Overlays.Settings.Sections.Input
|
||||
{
|
||||
base.LoadComplete();
|
||||
|
||||
configSensitivity.BindValueChanged(val => localSensitivity.Value = val.NewValue, true);
|
||||
configSensitivity.BindValueChanged(val =>
|
||||
{
|
||||
var disabled = localSensitivity.Disabled;
|
||||
|
||||
localSensitivity.Disabled = false;
|
||||
localSensitivity.Value = val.NewValue;
|
||||
localSensitivity.Disabled = disabled;
|
||||
}, true);
|
||||
|
||||
localSensitivity.BindValueChanged(val => configSensitivity.Value = val.NewValue);
|
||||
|
||||
windowMode.BindValueChanged(mode =>
|
||||
|
Loading…
Reference in New Issue
Block a user