1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-15 16:03:01 +08:00

Fix incorrect colour usage

This commit is contained in:
Dean Herbert 2019-08-25 11:44:56 +09:00
parent a19a9b90ed
commit 2e21fbcf6a
3 changed files with 4 additions and 4 deletions

View File

@ -151,7 +151,7 @@ namespace osu.Game.Overlays.Direct
AutoSizeAxes = Axes.X,
Height = 20,
Margin = new MarginPadding { Top = vertical_padding, Bottom = vertical_padding },
Children = GetDifficultyIcons(),
Children = GetDifficultyIcons(colours),
},
},
},

View File

@ -129,7 +129,7 @@ namespace osu.Game.Overlays.Direct
AutoSizeAxes = Axes.X,
Height = 20,
Margin = new MarginPadding { Top = vertical_padding, Bottom = vertical_padding },
Children = GetDifficultyIcons(),
Children = GetDifficultyIcons(colours),
},
},
},

View File

@ -139,14 +139,14 @@ namespace osu.Game.Overlays.Direct
};
}
protected List<DifficultyIcon> GetDifficultyIcons()
protected List<DifficultyIcon> GetDifficultyIcons(OsuColour colours)
{
var icons = new List<DifficultyIcon>();
if (SetInfo.Beatmaps.Count > maximum_difficulty_icons)
{
foreach (var ruleset in SetInfo.Beatmaps.Select(b => b.Ruleset).Distinct())
icons.Add(new GroupedDifficultyIcon(SetInfo.Beatmaps.FindAll(b => b.Ruleset.Equals(ruleset)), ruleset, this is DirectListPanel ? Color4.White : Color4.Black));
icons.Add(new GroupedDifficultyIcon(SetInfo.Beatmaps.FindAll(b => b.Ruleset.Equals(ruleset)), ruleset, this is DirectListPanel ? Color4.White : colours.Gray5));
}
else
foreach (var b in SetInfo.Beatmaps.OrderBy(beatmap => beatmap.StarDifficulty))