mirror of
https://github.com/ppy/osu.git
synced 2025-01-15 09:22:54 +08:00
Rename to alwaysShow and add XMLDoc
This commit is contained in:
parent
0f449d1b99
commit
4cdf4b223c
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user