style: nullable pass on KeyCounterDisplay

This commit is contained in:
tsrk 2023-02-15 22:06:10 +00:00
parent 076eb81b21
commit b0a2e69f95
No known key found for this signature in database
GPG Key ID: EBD46BB3049B56D6
2 changed files with 7 additions and 10 deletions

View File

@ -24,12 +24,11 @@ namespace osu.Game.Screens.Play
public DefaultKeyCounterDisplay()
{
InternalChild = KeyFlow = new FillFlowContainer<KeyCounter>
{
Direction = FillDirection.Horizontal,
AutoSizeAxes = Axes.Both,
Alpha = 0,
};
KeyFlow.Direction = FillDirection.Horizontal;
KeyFlow.AutoSizeAxes = Axes.Both;
KeyFlow.Alpha = 0;
InternalChild = KeyFlow;
}
protected override void Update()

View File

@ -1,8 +1,6 @@
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
#nullable disable
using System;
using System.Linq;
using osu.Framework.Allocation;
@ -19,7 +17,7 @@ namespace osu.Game.Screens.Play
{
protected readonly Bindable<bool> ConfigVisibility = new Bindable<bool>();
protected FillFlowContainer<KeyCounter> KeyFlow;
protected FillFlowContainer<KeyCounter> KeyFlow = new FillFlowContainer<KeyCounter>();
protected override Container<KeyCounter> Content => KeyFlow;
@ -71,7 +69,7 @@ namespace osu.Game.Screens.Play
public override bool HandleNonPositionalInput => receptor == null;
public override bool HandlePositionalInput => receptor == null;
private Receptor receptor;
private Receptor? receptor;
public void SetReceptor(Receptor receptor)
{