mirror of
https://github.com/ppy/osu.git
synced 2024-12-15 08:13:31 +08:00
Fix possible multiple enumeration
This commit is contained in:
parent
eeb66a955e
commit
b9220d4dc7
@ -57,11 +57,13 @@ namespace osu.Game.Tests.Visual.UserInterface
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
var coverTypes = Enum.GetValues(typeof(BeatmapSetCoverType)).Cast<BeatmapSetCoverType>();
|
var coverTypes = Enum.GetValues(typeof(BeatmapSetCoverType))
|
||||||
|
.Cast<BeatmapSetCoverType>()
|
||||||
|
.ToList();
|
||||||
|
|
||||||
for (int i = 0; i < 25; i++)
|
for (int i = 0; i < 25; i++)
|
||||||
{
|
{
|
||||||
var coverType = coverTypes.ElementAt(i % coverTypes.Count());
|
var coverType = coverTypes[i % coverTypes.Count];
|
||||||
|
|
||||||
var cover = new UpdateableBeatmapSetCover(coverType)
|
var cover = new UpdateableBeatmapSetCover(coverType)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user