Rename the nullable disable annotation in the Audio namespace and mark some properties as nullable.

This commit is contained in:
andy840119
2022-07-31 22:00:14 +08:00
parent 998e3b74d6
commit 6c964dee30
8 changed files with 6 additions and 22 deletions

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 osu.Framework.Allocation;
using osu.Framework.Audio;
using osu.Framework.Audio.Track;
@ -20,9 +18,9 @@ namespace osu.Game.Audio
private readonly BindableDouble muteBindable = new BindableDouble();
private ITrackStore trackStore;
private ITrackStore trackStore = null!;
protected TrackManagerPreviewTrack CurrentTrack;
protected TrackManagerPreviewTrack? CurrentTrack;
public PreviewTrackManager(IAdjustableAudioComponent mainTrackAdjustments)
{
@ -90,7 +88,7 @@ namespace osu.Game.Audio
public class TrackManagerPreviewTrack : PreviewTrack
{
[Resolved(canBeNull: true)]
public IPreviewTrackOwner Owner { get; private set; }
public IPreviewTrackOwner? Owner { get; private set; }
private readonly IBeatmapSetInfo beatmapSetInfo;
private readonly ITrackStore trackManager;