diff --git a/osu.Game/Configuration/OsuConfigManager.cs b/osu.Game/Configuration/OsuConfigManager.cs index be293d02f6..aced8e3024 100644 --- a/osu.Game/Configuration/OsuConfigManager.cs +++ b/osu.Game/Configuration/OsuConfigManager.cs @@ -1,8 +1,10 @@ // Copyright (c) 2007-2018 ppy Pty Ltd . // Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE +using System; using osu.Framework.Configuration; using osu.Framework.Configuration.Tracking; +using osu.Framework.Extensions; using osu.Framework.Platform; using osu.Game.Overlays; using osu.Game.Rulesets.Scoring; @@ -106,14 +108,29 @@ namespace osu.Game.Configuration Set(OsuSetting.ScalingPositionY, 0.5f, 0f, 1f); } - public OsuConfigManager(Storage storage) : base(storage) + public OsuConfigManager(Storage storage) + : base(storage) { } - public override TrackedSettings CreateTrackedSettings() => new TrackedSettings + public override TrackedSettings CreateTrackedSettings() { - new TrackedSetting(OsuSetting.MouseDisableButtons, v => new SettingDescription(!v, "gameplay mouse buttons", v ? "disabled" : "enabled")) - }; + Func scalingDescription = () => + { + var scalingMode = Get(OsuSetting.Scaling); + return new SettingDescription(scalingMode, "scaling", scalingMode.GetDescription()); + }; + + return new TrackedSettings + { + new TrackedSetting(OsuSetting.MouseDisableButtons, v => new SettingDescription(!v, "gameplay mouse buttons", v ? "disabled" : "enabled")), + new TrackedSetting(OsuSetting.Scaling, _ => scalingDescription()), + new TrackedSetting(OsuSetting.ScalingSizeX, _ => scalingDescription()), + new TrackedSetting(OsuSetting.ScalingSizeY, _ => scalingDescription()), + new TrackedSetting(OsuSetting.ScalingPositionX, _ => scalingDescription()), + new TrackedSetting(OsuSetting.ScalingPositionY, _ => scalingDescription()), + }; + } } public enum OsuSetting diff --git a/osu.Game/Configuration/ScalingMode.cs b/osu.Game/Configuration/ScalingMode.cs index 063e967fa3..9673cc9251 100644 --- a/osu.Game/Configuration/ScalingMode.cs +++ b/osu.Game/Configuration/ScalingMode.cs @@ -1,12 +1,17 @@ // Copyright (c) 2007-2019 ppy Pty Ltd . // Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE + +using System.ComponentModel; + namespace osu.Game.Configuration { public enum ScalingMode { + Off, Everything, + [Description("Excluding overlays")] ExcludeOverlays, Gameplay, } -} \ No newline at end of file +}