mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 15:44:04 +09:00
Fix many warnings
This commit is contained in:
@ -547,6 +547,7 @@ namespace osu.Game.Screens.Select
|
||||
|
||||
float? setY = null;
|
||||
if (!d.IsLoaded || beatmap.Alpha == 0) // can't use IsPresent due to DrawableCarouselItem override.
|
||||
// ReSharper disable once PossibleNullReferenceException (resharper broken?)
|
||||
setY = lastSet.Y + lastSet.DrawHeight + 5;
|
||||
|
||||
if (d.IsLoaded)
|
||||
|
@ -254,7 +254,7 @@ namespace osu.Game.Screens.Select
|
||||
|
||||
private OsuSpriteText[] getMapper(BeatmapMetadata metadata)
|
||||
{
|
||||
if (string.IsNullOrEmpty(metadata.Author?.Username))
|
||||
if (metadata.Author == null || string.IsNullOrEmpty(metadata.Author.Username))
|
||||
return Array.Empty<OsuSpriteText>();
|
||||
|
||||
return new[]
|
||||
|
@ -3,6 +3,7 @@
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using OpenTK.Input;
|
||||
using osu.Framework.Allocation;
|
||||
using osu.Framework.Audio;
|
||||
@ -75,7 +76,8 @@ namespace osu.Game.Screens.Select
|
||||
{
|
||||
// if we have no beatmaps but osu-stable is found, let's prompt the user to import.
|
||||
if (!beatmaps.GetAllUsableBeatmapSets().Any() && beatmaps.StableInstallationAvailable)
|
||||
dialogOverlay.Push(new ImportFromStablePopup(() => beatmaps.ImportFromStable()));
|
||||
dialogOverlay.Push(new ImportFromStablePopup(() =>
|
||||
Task.Factory.StartNew(beatmaps.ImportFromStable, TaskCreationOptions.LongRunning)));
|
||||
});
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user