mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 15:07:44 +08:00
Address linting issues
This commit is contained in:
parent
267238dc27
commit
2b1d31e69c
@ -1,11 +1,9 @@
|
||||
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
|
||||
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
|
||||
|
||||
using System;
|
||||
using osu.Framework.Audio.Track;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Beatmaps.IO;
|
||||
|
||||
namespace osu.Desktop.VisualTests.Beatmaps
|
||||
{
|
||||
|
@ -8,7 +8,6 @@ using osu.Framework.MathUtils;
|
||||
using osu.Framework.Screens.Testing;
|
||||
using osu.Framework.Timing;
|
||||
using osu.Game.Beatmaps;
|
||||
using osu.Game.Beatmaps.IO;
|
||||
using osu.Game.Database;
|
||||
using osu.Game.Modes.Catch.UI;
|
||||
using osu.Game.Modes.Mania.UI;
|
||||
@ -17,7 +16,6 @@ using osu.Game.Modes.Osu.Objects;
|
||||
using osu.Game.Modes.Osu.UI;
|
||||
using osu.Game.Modes.Taiko.UI;
|
||||
using System.Collections.Generic;
|
||||
using osu.Framework.Graphics.Textures;
|
||||
using osu.Desktop.VisualTests.Beatmaps;
|
||||
|
||||
namespace osu.Desktop.VisualTests.Tests
|
||||
|
@ -8,7 +8,6 @@ using osu.Framework.Screens.Testing;
|
||||
using osu.Game.Beatmaps;
|
||||
using OpenTK;
|
||||
using osu.Framework.Graphics.Sprites;
|
||||
using osu.Game.Beatmaps.IO;
|
||||
using osu.Game.Database;
|
||||
using osu.Game.Modes;
|
||||
using osu.Game.Modes.Objects;
|
||||
@ -24,7 +23,6 @@ namespace osu.Desktop.VisualTests.Tests
|
||||
protected Player Player;
|
||||
private BeatmapDatabase db;
|
||||
|
||||
|
||||
public override string Description => @"Showing everything to play the game.";
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
|
@ -22,14 +22,14 @@ namespace osu.Game.Database
|
||||
this.database = database;
|
||||
}
|
||||
|
||||
private ArchiveReader GetReader() => database?.GetReader(BeatmapSetInfo);
|
||||
private ArchiveReader getReader() => database?.GetReader(BeatmapSetInfo);
|
||||
|
||||
protected override Beatmap GetBeatmap()
|
||||
{
|
||||
Beatmap beatmap;
|
||||
try
|
||||
{
|
||||
using (var reader = GetReader())
|
||||
using (var reader = getReader())
|
||||
{
|
||||
BeatmapDecoder decoder;
|
||||
using (var stream = new StreamReader(reader.GetStream(BeatmapInfo.Path)))
|
||||
@ -40,7 +40,7 @@ namespace osu.Game.Database
|
||||
|
||||
if (WithStoryboard && beatmap != null && BeatmapSetInfo.StoryboardFile != null)
|
||||
using (var stream = new StreamReader(reader.GetStream(BeatmapSetInfo.StoryboardFile)))
|
||||
decoder?.Decode(stream, beatmap);
|
||||
decoder.Decode(stream, beatmap);
|
||||
}
|
||||
}
|
||||
catch { return null; }
|
||||
@ -54,7 +54,7 @@ namespace osu.Game.Database
|
||||
return null;
|
||||
try
|
||||
{
|
||||
using (var reader = GetReader())
|
||||
using (var reader = getReader())
|
||||
{
|
||||
background = new TextureStore(
|
||||
new RawTextureLoaderStore(reader),
|
||||
@ -72,7 +72,7 @@ namespace osu.Game.Database
|
||||
try
|
||||
{
|
||||
//store a reference to the reader as we may continue accessing the stream in the background.
|
||||
trackReader = GetReader();
|
||||
trackReader = getReader();
|
||||
var trackData = trackReader?.GetStream(BeatmapInfo.Metadata.AudioFile);
|
||||
track = trackData == null ? null : new TrackBass(trackData);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user