1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 12:47:25 +08:00

Rename to alwaysShow and add XMLDoc

This commit is contained in:
Salman Ahmed 2020-02-02 18:47:12 +03:00
parent 0f449d1b99
commit 4cdf4b223c

View File

@ -19,8 +19,13 @@ namespace osu.Game.Screens.Play
private const int duration = 100;
private const double key_fade_time = 80;
/// <summary>
/// Whether to always show key counter regardless of <see cref="Visible"/>.
/// This is bound to <see cref="OsuSetting.KeyOverlay"/> configuration setting bindable.
/// </summary>
private readonly Bindable<bool> alwaysShow = new Bindable<bool>();
public readonly Bindable<bool> Visible = new Bindable<bool>(true);
protected readonly Bindable<bool> ConfigVisibility = new Bindable<bool>();
protected readonly FillFlowContainer<KeyCounter> KeyFlow;
@ -51,7 +56,7 @@ namespace osu.Game.Screens.Play
[BackgroundDependencyLoader]
private void load(OsuConfigManager config)
{
config.BindWith(OsuSetting.KeyOverlay, ConfigVisibility);
config.BindWith(OsuSetting.KeyOverlay, alwaysShow);
}
protected override void LoadComplete()
@ -59,7 +64,7 @@ namespace osu.Game.Screens.Play
base.LoadComplete();
Visible.BindValueChanged(_ => updateVisibility());
ConfigVisibility.BindValueChanged(_ => updateVisibility(), true);
alwaysShow.BindValueChanged(_ => updateVisibility(), true);
}
private bool isCounting = true;